mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-05-03 11:47:50 +07:00
10 lines
289 B
Java
10 lines
289 B
Java
// "Replace with count()" "true"
|
|
|
|
import java.util.Arrays;
|
|
|
|
public class Main {
|
|
public long test(String[] array, long limit) {
|
|
long longStrings = Arrays.stream(array).map(String::trim).filter(trimmed -> trimmed.length() > 10).limit(limit + 1).count();
|
|
return longStrings;
|
|
}
|
|
} |