mirror of
https://gitflic.ru/project/openide/openide.git
synced 2025-12-17 15:50:53 +07:00
Also declaration is joined automatically GitOrigin-RevId: f94ddf5ae3e94edffdb44cd56ad6bf8b3a9054b4
15 lines
444 B
Java
15 lines
444 B
Java
// "Fix all ''compare()' method can be used to compare numbers' problems in file" "true"
|
|
class Test {
|
|
public void test(String s1, String s2) {
|
|
int res = Integer.compare(s2.length(), s1.length());
|
|
System.out.println(res);
|
|
}
|
|
|
|
public void testMissingElse(String s1, String s2) {
|
|
int res;
|
|
if(s1.length() < s2.length()) res = 1;
|
|
else if(s1.length() > s2.length()) res = -1;
|
|
res = 0;
|
|
System.out.println(res);
|
|
}
|
|
} |