

MCQOPTIONS
This section includes 2 Mcqs, each offering curated multiple-choice questions to sharpen your Java Dot lang Class Finding the output knowledge and support exam preparation. Choose a topic below to get started.
1. |
What will be the output of the program? public class WrapTest if (x == y) /* Line 13 */ System.out.println("result = " + result);
|
A. | result = 1 |
B. | result = 10 |
C. | result = 11 |
D. | result = 11010 |
Answer» C. result = 11 | |
2. |
What will be the output of the program? String x = new String("xyz"); How many String objects have been created? |
A. | 2 |
B. | 3 |
C. | 4 |
D. | 5 |
Answer» D. 5 | |