Variable passing, Error: IOException
Hi, I am working on a project and trying to get this to work.
Code:
import java.io.IOException;
public class clearrun
{
public static void clearrun(String args[])
throws IOException
{
int a=0;
clearrun(a);
}
public static void clearrun(int a)
throws IOException
{
System.out.println(""+a);
}
}
So far it compiles correctly but when it runs it says error. The method clearrun is designed to receive a integer and display it the throws IOException is put in there as a safe gaurd from the other program accessing it using User Responses. But when i run it there is an error about main or something.
Thanks.