mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-01-11 11:36:59 +07:00
18 lines
431 B
Java
18 lines
431 B
Java
// "Replace Stream API chain with loop" "true"
|
|
|
|
import java.util.IntSummaryStatistics;
|
|
import java.util.stream.IntStream;
|
|
|
|
public class Main {
|
|
private static IntSummaryStatistics test() {
|
|
IntSummaryStatistics stat = new IntSummaryStatistics();
|
|
for (int i : new int[]{1, 2, 3}) {
|
|
stat.accept(i);
|
|
}
|
|
return stat;
|
|
}
|
|
|
|
public static void main(String[] args) {
|
|
System.out.println(test());
|
|
}
|
|
} |