fork download
  1. importPackage(java.io);
  2. importPackage(java.lang);
  3.  
  4. var reader = new BufferedReader( new InputStreamReader(System['in']) );
  5.  
  6. const a = {}
  7.  
  8. for (let i=0; i<1000; i++) {
  9. a[i] = i
  10. }
  11.  
  12.  
  13. while(true) {
  14. var line = reader.readLine();
  15. if(line == null || line == "42") {
  16. break;
  17. } else {
  18. System.out.println(line);
  19. }
  20. }
Success #stdin #stdout 0.56s 44324KB
stdin
hello
hi
alloha
stdout
hello
hi
alloha