I am having problems with STDIN
I would to read the following 2 string, for example:
Input:
abc
xyz
When typing "abc", then press Enter, I get abc back. However i dont want that. I would like to type another string just like input above.
So what want is: Type abc, Enter, type xyz enter
here is my code:
BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
String s;
while ((s = in.readLine()) != null && s.length() != 0){
System.out.println(s);
}
Thanks