You are not logged in.

#1 2015-06-10 10:34:46

husnain
User RankUser RankUser RankUser RankUser RankUser Rank
Administrator
From: Chichawatni,Pakistan
Registered: 2014-10-03
Posts: 8,129
Website

Runnable Implements:

Question:
public Class Test implements Runnable{
public void run(Thread t)
{
System.out.println(Running...);
}
public static void main(String [] args)
{
new thread(new Test()).start();
}
}
What is the result?

Option A):
Running will be printed
Option B):
Exception is thrown
Option C):
Compile error
Option D):
Program exists without printing anything

Correct Answer is Option C):
Compile error


You cannot discover the new oceans unless you have the courage to lose the sight of the shore.

2015-06-10 10:34:46

Advertisement
Ads By Google

Re: Runnable Implements:



Board footer