Card 22 / 32: public class TestString1 { public static void main(String[] args) { Runnable r = new Runnable() { public void run() { System.out.println("Cat.."); } }; Thread t = new Thread(r){ public void run(){ System.out.println("Dog.."); } }; t.start(); } }
A)
Cat
B)
Dog
C)
CatDog
D)
Exception thrown that runtime
Answer:
B) Dog
Previous Card | ← Previous Card Button |
Next Card | → Next Card Button |
Flip Card | Space-Bar |
|