http://www.javaprogrammingforums.com/whats-wrong-my-code/26264-java-program-reads-file.html
Duplicate
Type: Posts; User: Starstreak
http://www.javaprogrammingforums.com/whats-wrong-my-code/26264-java-program-reads-file.html
Duplicate
Your scanner is reading from System.in, where it should be reading from the file.
Try and use NIO. The earlier stuff is classed as "legacy i/o".
...