mirror of
https://github.com/jashkenas/coffeescript.git
synced 2026-02-18 11:31:20 -05:00
trying out new arrows for function literals -> is a function, => is a bound function
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
# A bubble sort implementation, sorting the given array in-place.
|
||||
bubble_sort: (list) =>
|
||||
bubble_sort: (list) ->
|
||||
for i in [0...list.length]
|
||||
for j in [0...list.length - i]
|
||||
[list[j], list[j+1]]: [list[j+1], list[j]] if list[j] > list[j+1]
|
||||
|
||||
Reference in New Issue
Block a user