Test : Java_1
This test contains 10 questions based on Java.
Each question answered correctly awards you 1 point and each incorrect answer has a penalty of -0.25 points, no points are deducted for unattempted answers.
Each question answered correctly awards you 1 point and each incorrect answer has a penalty of -0.25 points, no points are deducted for unattempted answers.
Select Test Type
You Get +1 for each correct answer and -0.25 for each incorrect answer
Time Left - minutes :seconds
What was the original name of Java
Oak | Pok |
James | Coffee |
Who is know as the father of Java
Ken Arnold | David Holmes |
James Gosling | Peter Dibble |
Java Source Code is compiled into which format
.java | .class |
.exe | .bytecode |
Which tool is used to compile Java Code
java | javac |
javah | javacpl |
What is byte code in the context of Java ?
The type of code generated by a Java compiler | The type of code generated by a Java Virtual Machine |
It is another name for a Java source file | It is the code written within the instance methods of a class |
What is the output of this program?
class box { int width; int height; int length; } class mainclass { public static void main(String args[]) { box obj1 = new box(); box obj2 = new box(); obj1.height = 1; obj1.length = 2; obj1.width = 1; obj2 = obj1; System.out.println(obj2.height); } }
1 | 2 |
4 | 6 |
What is the output of this program?
class box { int width; int height; int length; } class mainclass { public static void main(String args[]) { box obj = new box(); System.out.println(obj); } }
0 | 1 |
Runtime error | Garbage value |
Which of these functions is called to display the output of an applet?
display() | print() |
displayApplet() | PrintApplet() |
Which of these methods can be used to output a sting in an applet?
display() | print() |
drawString() | transient() |
What does AWT stands for?
All Window Tools | All Writing Tools |
Abstract Window Toolkit | Abstract Writing Toolkit |
Finish Test
No comments: