and1dude 0 Newbie Poster

Hi, how can i ignore the blank lines in a input file?

input:
Name value
departure city value value
arrival city value
distance value

Name value
departure city value value
arrival city value
distance value
etc....

I used 2 scanners,
First one scanner if there is nextLine(), then send the line into an other method
then i scan that line in the method and determine the field name and sort the value.

if there way to ignore blank lines