hai all
i have a doubt regarding the start() method of
Thread class. start() implicitly calls the run() method of that class. o.k
but what is the problem if i override the start().
why in my follwing code after completing the start method in PrintNumThread
class the control fails to go to the run() method ???
plz clarify.
ritwik
class TestThread
{
public static void main(
String arg[])
{
PrintNumThread pnt=new PrintNumThread();
pnt.start();
}
}
class PrintNumThread extends Thread
{
public void start()
{
System.out.println("PrintNumThread Started");
}
public void run()
{
for(int i=0;i<5;i++)
{
System.out.println(i);
}
}
}