mirror of
https://github.com/tiennm99/lombok.git
synced 2026-05-28 10:23:55 +00:00
12 lines
231 B
Java
12 lines
231 B
Java
//version :9
|
|
import lombok.var;
|
|
|
|
public class VarInFor {
|
|
public void enhancedFor() {
|
|
int[] list = new int[] {1, 2};
|
|
for (var shouldBeInt : list) {
|
|
System.out.println(shouldBeInt);
|
|
var shouldBeInt2 = shouldBeInt;
|
|
}
|
|
}
|
|
} |