what is an EOF? and how do I solve it? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 3

what is an EOF? and how do I solve it?

24th Oct 2016, 6:28 PM
Edwin Pratt
Edwin Pratt - avatar
2 Answers
+ 2
EOF is End Of File, and generally you can see these types of issues occur when you forget to close something, i.e. with ),], or }
24th Oct 2016, 8:47 PM
Alex Schrichte
Alex Schrichte - avatar
+ 1
If you are reading a stream there is usually a method called hasNext() returning a Boolean. This can be used to prevent running into empty space.
25th Oct 2016, 6:27 AM
Carl Fies
Carl Fies - avatar