Which of the following will create instance of Runnable type?
A. Runnable run = () -> {System.out.println("Run");}
B. Runnable run = () -> System.outprintlnfRun");
C. Runnable run = () > System.outpr...
What is the result?
A.
sc: class Object
asc: class AnotherSampleClass
B.
sc: class SampleClass
asc: class AnotherSampleClass
C.
sc: class AnotherSampleClass
asc: class SampleClass
D.
sc: class Anothe...
What is the result?
A.
p1.Test.class
0.0
B
<the summary address refrenced by ref>
0.000000
C.
Null
0.0
D. Compilation fails
E. A NullPointerException is thrown at runtime
What is the result?
A.
100
210
B. Compilation fails due to an error in line n1
C. Compilation fails due to an error at line n2
D. Compilation fails due to an error at line n3
Which code fragment, when inserted at line n1, enables the App class to print Equal?
A.
String str3 = str2;
if (str1 == str3)
B.
if (str1.equalsIgnoreCase(str2))
C.
String str3 = str2;
if (str1.equal...