Programming Language Java thread MCQ Question #2298
Single Choice Not Set

QWhat will be the output?
class One extends Thread{
	public void run(){
		for(int i=0; i<2; i++){
			System.out.print(i);
		}
	}
}

public class Test{
	public static void main(String args[]){
		Test t = new Test();
		t.call(new One());
	}
	
	public void call(One o){
		o.start();
	}
}

ID: #2298 Java thread MCQ 1,923 views
Question Info
#2298Q ID
Not SetDifficulty
Java thread MCQTopic

Choose the Best Option

Click any option to instantly check if you're correct.

  • A 0 0
  • B Compilation Error
  • C 0 1
  • D None of these
Correct Answer

Explanation

0 1

Share This Question

Challenge a friend or share with your study group.