generator

Run Settings
LanguageJava
Language Version
Run Command
import java.util.function.*; import java.util.concurrent.atomic.AtomicInteger; class Main { public static void main(String[] args) { Supplier<IntSupplier> generateIntGenerator = () -> { var i = new AtomicInteger(); return i::getAndIncrement; }; var generator = generateIntGenerator.get(); System.out.println(generator.getAsInt()); System.out.println(generator.getAsInt()); System.out.println(generator.getAsInt()); System.out.println(generator.getAsInt()); } }
Editor Settings
Theme
Key bindings
Full width
Lines