Your input on the console will be the filename and hence that has to be fed as relative path as explained.
Type: Posts; User: dineshj83
Your input on the console will be the filename and hence that has to be fed as relative path as explained.
For example if your code is in src/<package>/file and your file is in the same level as src then give only file name if its in a folder then it will be like foldername/filename. Hope you got it now.
Thats why i asked you to relative path which will work even if you package it and share it as jar to external world. Only in absolute path you will point to any of your drives in PC. Hope you got it...
Are you giving relative path of the file to be read?.