Changed the while loop so it will forever loop.

If using a file in standard input, change this to while(count < x)
where x is the number of inputs in the file.