Thread: Buffered input?
View Single Post
Old Oct 31st, 2007, 8:56 PM   #6
~s.o.s~
Megalomaniac
 
~s.o.s~'s Avatar
 
Join Date: Nov 2006
Posts: 8
Rep Power: 0 ~s.o.s~ is on a distinguished road
Re: Buffered input?

> Why is there a need to use those lines of code when you use the readLine() function?
Scanner class was introduced in JDK 1.5 as a utility class which would serve as a golden hammer when doing I/O. Prior to that, if you wanted to accept user input via console, you had to use the BufferedReader, the way it is specified in the second post.
__________________
"Be and not seem."
~s.o.s~ is offline   Reply With Quote