PRO192_-_SP_2025_-_FE_3648.webp
Y

PRO192_-_SP_2025_-_FE_3648.webp

  • Media owner Yuji99
  • Ngày thêm
Kizspy Question: 30
(Choose 1 answer)
What is the output of the following Java program?
interface InfA {
static String message = "hello";
String getName();
public class Main implements InfA {
public String getName() {
return InfA.message;
public static void main(String[] args) {
Main t = new Main();
System.out.println(t.getName());
A. hello
B. Compile error because the variable message
declared with a static keyword
C. Runtime error because the interface InfA has no static method
D. None of the others

Thông tin

Category
PRO192
Thêm bởi
Yuji99
Ngày thêm
Lượt xem
3,616
Lượt bình luận
4
Rating
0.00 star(s) 0 đánh giá

Share this media

Back
Bên trên Bottom