The eclipse root directory is the base directory of the project (i.e., not the src / directory, directly under the project.)
Generally, a good style has a “resources” folder for txt, graphics, etc.
Instead of trying to transfer the stream, you can just pass the file name and open the stream itself.
The reason that you do in Eclipse does not work, because your command line / shell / dos / bash / whatever handles creating the input stream from the file for you. Eclipse does not. So, from the command line: < alice.txt means "run this program without arguments and create a stream for system.in", while in Eclipse means "run this program with two arguments" <'and' alice.txt '
source share