1z0-808 Korean試験無料問題集「Oracle Java SE 8 Programmer I (1z0-808 Korean Version) 認定」
주어진:
class Test {
public static void main (String[] args) {
int day = 1;
switch (day) {
case "7":
System.out.print("Uranus");
case "6":
System.out.print("Saturn");
case "1":
System.out.print("Mercury");
case "2":
System.out.print("Venus");
case "3":
System.out.print("Earth");
case "4":
System.out.print("Mars");
case "5":
System.out.print("Jupiter");
}
}
}
코드를 컴파일하고 실행할 수 있도록 독립적으로 수행된 두 가지 수정 사항은 무엇입니까?
class Test {
public static void main (String[] args) {
int day = 1;
switch (day) {
case "7":
System.out.print("Uranus");
case "6":
System.out.print("Saturn");
case "1":
System.out.print("Mercury");
case "2":
System.out.print("Venus");
case "3":
System.out.print("Earth");
case "4":
System.out.print("Mars");
case "5":
System.out.print("Jupiter");
}
}
}
코드를 컴파일하고 실행할 수 있도록 독립적으로 수행된 두 가지 수정 사항은 무엇입니까?
正解:A,B
解答を投票する
주어진:
공개 클래스 ColorTest {
공개 정적 무효 메인(String[] args) {
String[] colors = {"빨간색", "파란색","녹색","노란색","적갈색","청록색"};
int count = 0;
for (String c : colors) {
if (count >= 4) {
break;
}
else {
continue;
}
if (c.length() >= 4) {
colors[count] = c.substring(0,3);
}
count++;
}
System.out.println(colors[count]);
}
}
결과는 무엇입니까?
공개 클래스 ColorTest {
공개 정적 무효 메인(String[] args) {
String[] colors = {"빨간색", "파란색","녹색","노란색","적갈색","청록색"};
int count = 0;
for (String c : colors) {
if (count >= 4) {
break;
}
else {
continue;
}
if (c.length() >= 4) {
colors[count] = c.substring(0,3);
}
count++;
}
System.out.println(colors[count]);
}
}
결과는 무엇입니까?
正解:C
解答を投票する
解説: (GoShiken メンバーにのみ表示されます)









