Given:
11. public static void main(String[] args) {
12. Integer i = uew Integer(1) + new Integer(2);
13. switch(i) {
14. case 3: System.out.println(”three”); break;
15. default: System.out.println(”other”); break;
16. }
17. }
‘What is the result?
1 three
2 other
3 An exception is thrown at runtime.
4 Compilation fails because of an error on
line 12.
Answer Posted / harish
Compilation fails because of an error on
| Is This Answer Correct ? | 5 Yes | 12 No |
Post New Answer View All Answers
What is parsing and its types?
What is the difference between the file and randomaccessfile classes?
Is singleton class thread safe?
What do you mean by formatting?
Explain when noclassdeffounderror will be raised ?
What function extracts specified characters from a string?
What is mvc in java?
What is data type example?
What is a parameter in a function?
What is a list in java?
What is nextline method in java?
What are operators and its types?
How many bits is a string?
What are benefits of java?
What does exp mean in math?