Skip to content

Commit 461d304

Browse files
author
lucifer
committed
fix: typo
1 parent 740f69c commit 461d304

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Diff for: thinkings/heap.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -781,7 +781,7 @@ public class Heap {
781781
}
782782

783783
public void buildHeap() {
784-
for (int i = size >> 1; i >= 0; i--) {
784+
for (int i = size >> 1; i > 0; i--) {
785785
shiftDown(i);
786786
}
787787
}

0 commit comments

Comments
 (0)