Java MCQ's on Fundamentals Of Java
This test contains 10 questions based on Fundamentals Of 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.
Select Test Type
You Get +1 for each correct answer and -0.25 for each incorrect answer
Time Left -
minutes
:
seconds
Which of the following is not a conditional statement.
| while | if |
| for | do while |
Which of the following is not a keyword in java.
| volatile | clazz |
| private | transient |
Which of the following is not an Object.
| Integer | Boolean |
| String | char |
Which of these is invalid.
| char A = 1 | char A = 'A' |
| char A = "A" | Both A and C |
Which of the following is the parent class of all the classes.
| Lang | Object |
| Java | None of these |
Can we force garbace collection in Java.
| Yes | No |
Which of the following is not a type of variable.
| transient | volatile |
| native | final |
How many diffrent values can an integer have in java.
| 28 | 216 |
| 232 | 264 |
What will be the output of the following program.
class A{
public static void main(String args[]){
char a = 1;
int n = 1;
System.out.println(a == n);
}
}
| Compilation Error | true |
| false | None of these |
Which of the following is an invalid in java
| a = ++a; | a -= --a; |
| a %= a; | None of these |
Finish Test
No comments: