Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitf3f2661

Browse files
author
MK
committed
Solve the Optimize method flip in SortUtilsTheAlgorithms#1246
1 parentd678fae commitf3f2661

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

‎src/main/java/com/sorts/SortUtils.java‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ static <T extends Comparable<T>> boolean less(T v, T w) {
3838
* @param right is a right flip border of the array
3939
*/
4040
static <TextendsComparable<T>>voidflip(T[]array,intleft,intright) {
41-
while (left <=right) {
41+
while (left <right) {
4242
swap(array,left++,right--);
4343
}
4444
}

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp