mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-05-03 03:37:58 +07:00
19 lines
403 B
Java
19 lines
403 B
Java
// "Replace with findFirst()" "true"
|
|
|
|
public class Test {
|
|
public static void main(String[] args) {
|
|
String s = " hello ";
|
|
String res = s.trim();
|
|
if(args.length == 0) {
|
|
for (<caret>int i = 0; i < s.length(); i++) {
|
|
Integer x = i;
|
|
if (s.charAt(x) == 'l') {
|
|
res = String.valueOf(x);
|
|
break;
|
|
}
|
|
}
|
|
}
|
|
System.out.println(res);
|
|
}
|
|
}
|