4. |
Which answers are true about the following program?
public class Example {
public static void main(String[] args) {
String s = "123";
Object o = s;
s = (String)o;
System.out.println(s);
}
}
Please select all the correct answers.
|
|
A. |
An error is generated when the program is compiled.
|
|
B. |
The program displays the value String["123"] .
|
|
C. |
The program displays the value 123
|
|
D. |
The program generates a RuntimeException .
|