I have written a program to get the input from a file using DataInputStream and display it on console. The Program is as follows:
The problem that is coming is the output on the console is not human readable. Please tell where i am going wrong.
Joined: Mar 22, 2005
DataInputStream is not meant for reading clear text (which is what you're doing, judging from the filename). Leave it out and use the BufferedInputStream directly, or -even better- wrap it in a BufferedReader that allows you to read line by line.