- A Compilation fails.
- B An exception is thrown at runtime.
- C "go" is printed
- D "gogogo" is printed
Java Programming Language MCQ Java thread MCQ
⚠ Report ✓ Question Verified Copy Link
public class Test implements Runnable{
public void run(){
System.out.print("go");
}
public static void main(String arg[]) {
Thread t = new Thread(new Test());
t.run();
t.run();
t.start();
}
}
Learn More MCQ Questions from Java Programming Language MCQ Java thread MCQ