Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I learned to read line as the following in Java 1.2 so the Scanner class is new to me. :p

  BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
  String input = in.readLine();


Yep, same for me, it's been a long time since I did java and while the publicstaticvoidmain mantra felt familiar I was a bit confused by the Scanner thing and couldn't say why.


Same here, oddly pleased that the Scanner class is deprecated before I even knew about it.




Consider applying for YC's Winter 2026 batch! Applications are open till Nov 10

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: