fork download
  1. import java.util.stream.*;
  2.  
  3. public class Main {
  4. public static void main(String[] args) {
  5. IntStream.range(0, 9).asDoubleStream().map(e -> Math.pow(2, -e)).forEach(v -> System.out.println(v));
  6. }
  7. }
  8.  
Success #stdin #stdout 0.1s 40672KB
stdin
Standard input is empty
stdout
1.0
0.5
0.25
0.125
0.0625
0.03125
0.015625
0.0078125
0.00390625