Reputation: 28648
I would like to read from standard input word by word (i.e., the input string is always a collection of words separated with blanks). Now I'm using the read
function and I read the input char by char.
Is it possible? Thanks!
Upvotes: 0
Views: 1016
Reputation: 4353
With readln (readline) you can read a whole line that you can split into separate words. There is no function to read words from a file.
Upvotes: 2