11:47 AM .’Il T-Mobile Wi-Fi令 8 of 8 Done code segment? Show transcribed image text 11:47 AM .’Il T-Mobile Wi-Fi令 8 of 8 Done code segment?
Solution
27) Answer: Option d) 10.0
Explanation:
Program:
public class MyClass {
public static void main(String args[]) {
System.out.println((double)12/2+4);
}
}
Output:
28) Answer: Option d) 2
Explanation:
Program:
public class MyClass {
public static void main(String args[]) {
System.out.println(15%3+2);
}
}
Output:
29) Answer: Option b) Weekend
Explanation:
Program:
public class MyClass {
public static void main(String args[]) {
switch(0){
case 1:
case 2:
case 3:
case 4:
case 5:System.out.println(“Wednesday”);break;
case 0:
case 6:System.out.println(“Weekend”);
}
}
}
Output:
30) Answer: Option c) 3.0
Explanation:
Program:
public
OR
OR