Skip to content

Commit 62ccc34

Browse files
author
Michael Ye
committed
made bubblesort more idiomatic
1 parent 42c6fd2 commit 62ccc34

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

sort/bubblesort.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ func bubblesort(a []int) {
1616
hasChanged = true
1717
}
1818
}
19-
if hasChanged == false {
19+
if !hasChanged {
2020
break
2121
}
2222
}
23-
}
23+
}

0 commit comments

Comments
 (0)