Java Programming Questions & Answers: part1



Software Programming : Java Programming QUESTIONS AND ANSWERS :: part1 : 11 to 15

Following Software Programming language Entrance Multiple choice objective type questions and answers will help you in Software Programming 2015 examinations :

11.Among these expressions, which is(are) of type String?

"0"
"ab" + "cd"
'0'
Both (A) and (B) above
(A), (B) and (C) above.

12.To prevent any method from overriding, we declare the method as,

static
const
final
abstract
none of the above.

13.What will be printed as the output of the following program? #2. What will be printed as the output of the following program? public class testincr { public static void main(String args[]) { int i = 0; i = i++ + i; System.out.println("I = " +i); } }

I = 0
I = 1
I = 2
I = 3
Compile-time Error.

14.Which of the following variable declaration would NOT compile in a java program?

int var;
int VAR;
int var1;
int var_1;
int 1_var;.

More Java Programming QUESTIONS AND ANSWERS available in next pages

    Health is the greatest gift, contentment is the greatest wealth -Buddha