Skip to content

Instantly share code, notes, and snippets.

@shah-smit
Created February 17, 2017 11:39
Show Gist options
  • Save shah-smit/146913ed8f223b7d6c5df9ca7ebb1ee6 to your computer and use it in GitHub Desktop.
Save shah-smit/146913ed8f223b7d6c5df9ca7ebb1ee6 to your computer and use it in GitHub Desktop.
File Reader, its own in JAVA
import java.io.*;
public class filey
{
public static void bling(String s)throws Exception
{
BufferedReader inone = new BufferedReader(new FileReader(s));
int t = inone.read();
while(t != -1)
{
System.out.print((char)t);
t=inone.read();
}
}
public static void main(String[] args)throws Exception
{
bling(args[0]);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment