JAVA
2.7K subscribers
73 photos
111 files
76 links
Download Telegram
What will be the output?

public class Main
{
public static void main(String[] args) {
int num1, num2;
try{
num1 = 0;
num2 = 62/num1;
System.out.println("Try block message");
System.exit(0);
} catch(ArithmeticException e){
System.out.println("Error : Don't divide a number by zero");
System.exit(0);
} finally {
System.out.println("Give another number of num1");
}
}
}
Choose the correct option.

Which code segment should be used in place of missing Statement in the below code such that it displays the list of all root directories of the available system?

// Missing Statement

for(int i=0;i<dirs.length;i++)
System.out.println("Root["+i+"] : "+dirs[i]);
👍2😁1
What is the return type of Lambda expression?
Anonymous Quiz
18%
String
30%
Object
23%
Void
30%
Function
🤔15😁1
Which Spring annotation is used to create RESTful Web services using Spring MVC.
Anonymous Quiz
6%
🤔1