1Z1-803 無料問題集「Oracle Java SE 7 Programmer I」

public class StringReplace {
public static void main(String[] args) {
String message = "Hi everyone!";
System.out.println("message = " + message.replace("e", "X")); }
}
What is the result?

Given: What is the result?

Given the code fragment:
// insert code here arr[0] = new int[3]; arr[0][0] = 1; arr[0][1] = 2; arr[0][2] = 3;
arr[1] = new int[4]; arr[1][0] = 10; arr[1][1] = 20; arr[1][2] = 30; arr[1][3] = 40;
Which two statements, when inserted independently at line // insert code here, enable the code to compile?

正解:A、E 解答を投票する
Give:
Public Class Test {
}
Which two packages are automatically imported into the java source file by the java compiler?

正解:A、C 解答を投票する
解説: (JPNTest メンバーにのみ表示されます)
Given:
public class Painting {
private String type;
public String getType() {
return type;
}
public void setType(String type) {
this.type = type;
}
public static void main(String[] args) {
Painting obj1 = new Painting();
Painting obj2 = new Painting();
obj1.setType(null);
obj2.setType("Fresco");
System.out.print(obj1.getType() + " : " + obj2.getType());
}
}
What is the result?

Given:
public class DoBreak1 {
public static void main(String[] args) {
String[] table = {"aa", "bb", "cc", "dd"};
for (String ss: table) {
if ( "bb".equals(ss)) {
continue;
}
System.out.println(ss);
if ( "cc".equals(ss)) {
break;
}
}
} }
What is the result?

Identify two benefits of using ArrayList over array in software development.

正解:B、C 解答を投票する
解説: (JPNTest メンバーにのみ表示されます)
Given:
public class MyFor {
public static void main(String[] args) {
for (int ii = 0; ii < 4; ii++) {
System.out.println("ii = "+ ii);
ii = ii +1;
}
}
}
What is the result?

Which three statements are true about the structure of a Java class?

正解:B、E、F 解答を投票する
解説: (JPNTest メンバーにのみ表示されます)
Given:
interface Pet { }
class Dog implements Pet { }
public class Beagle extends Dog{ }
Which three are valid?

正解:B、D、F 解答を投票する
解説: (JPNTest メンバーにのみ表示されます)
Given:

How many times is 2 printed as a part of the output?

Given the classes:
*AssertionError
*ArithmeticException
*ArrayIndexOutofBoundsException
*FileNotFoundException
*IllegalArgumentException
*IOError
*IOException
*NumberFormatException
*SQLException
Which option lists only those classes that belong to the unchecked exception category?

解説: (JPNTest メンバーにのみ表示されます)
Given:

What is the result?

Given the code fragment:
Int [] [] array = {{0}, {0, 1}, {0, 2, 4}, {0, 3, 6, 9}, {0, 4, 8, 12, 16}};
Systemout.printIn(array [4] [1]);
System.out.printIn (array) [1] [4]);
What is the result?

解説: (JPNTest メンバーにのみ表示されます)
Given:
public class ColorTest {
public static void main(String[] args) {
String[] colors = {"red", "blue","green","yellow","maroon","cyan"};
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]);
}
}
What is the result?

解説: (JPNTest メンバーにのみ表示されます)
Given:

What is the result?

Given: What is the result?

弊社を連絡する

我々は12時間以内ですべてのお問い合わせを答えます。

オンラインサポート時間:( UTC+9 ) 9:00-24:00
月曜日から土曜日まで

サポート:現在連絡