최신Oracle Upgrade to Java SE 7 Programmer - 1Z1-805무료샘플문제
문제1
What is the minimum SQL standard that a JDBC API implementation must support?
What is the minimum SQL standard that a JDBC API implementation must support?
정답: A
설명: (KoreaDumps 회원만 볼 수 있음)
문제2
Given the code fragment:
Locale loc1 = Locale.getDefault ();
ResourceBundle messages = ResourceBundle.getBundle("MessageBundle", loc1);
Which two statements are a valid way to re-assign a resource bundle to a different Locale?
Given the code fragment:
Locale loc1 = Locale.getDefault ();
ResourceBundle messages = ResourceBundle.getBundle("MessageBundle", loc1);
Which two statements are a valid way to re-assign a resource bundle to a different Locale?
정답: A,D
문제3
Which three objects must a vendor provide implementations in its JDBC driver?
Which three objects must a vendor provide implementations in its JDBC driver?
정답: B,D,F
설명: (KoreaDumps 회원만 볼 수 있음)
문제4
Given:

What two changes should you make to apply the DAO pattern to this class?
Given:

What two changes should you make to apply the DAO pattern to this class?
정답: A,D
설명: (KoreaDumps 회원만 볼 수 있음)
문제5
Which two statements are true?
Which two statements are true?
정답: B,D
설명: (KoreaDumps 회원만 볼 수 있음)
문제6
The current working directory is named finance.
Which two code fragments allow you to write the salary.dat file if it does not exist under "finance\payroll"?
The current working directory is named finance.
Which two code fragments allow you to write the salary.dat file if it does not exist under "finance\payroll"?
정답: D,E
설명: (KoreaDumps 회원만 볼 수 있음)
문제7
Which two code blocks correctly initialize a Locale variable?
Which two code blocks correctly initialize a Locale variable?
정답: D,E
설명: (KoreaDumps 회원만 볼 수 있음)
문제8
View the Exhibit:

Given the following code fragment: class Finder extends SimpleFileVisitor<Path> { private final PathMatcher matcher; private static int numMatches = 0;
Finder() {
matcher = FileSystems.getDefault().getPathMatcher("glob:*java");
}
void find(Path file) {
Path Name = file.getFileName();
if (name != null && matcher.matches(name)) {
numMatches++;
}
}
void report()
{
System.out.println("Matched: " + numMatches);
}
@Override
public FileVisitResult visitFile(Path file, BasicFileAttributes attrs) {
find(file);
return CONTINUE;
}
}
public class Visitor {
public static void main(String[] args) throws IOException {
Finder finder = new Finder();
Files.walkFileTree(Paths.get("d:\\Project"), finder);
finder.report();
}
}
What is the result?
View the Exhibit:

Given the following code fragment: class Finder extends SimpleFileVisitor<Path> { private final PathMatcher matcher; private static int numMatches = 0;
Finder() {
matcher = FileSystems.getDefault().getPathMatcher("glob:*java");
}
void find(Path file) {
Path Name = file.getFileName();
if (name != null && matcher.matches(name)) {
numMatches++;
}
}
void report()
{
System.out.println("Matched: " + numMatches);
}
@Override
public FileVisitResult visitFile(Path file, BasicFileAttributes attrs) {
find(file);
return CONTINUE;
}
}
public class Visitor {
public static void main(String[] args) throws IOException {
Finder finder = new Finder();
Files.walkFileTree(Paths.get("d:\\Project"), finder);
finder.report();
}
}
What is the result?
정답: D
설명: (KoreaDumps 회원만 볼 수 있음)
문제9
Given:
import java.util.*;
public class StringApp {
public static void main (String [] args) {
Set <String> set = new TreeSet <> ();
set.add("X");
set.add("Y");
set.add("X");
set.add("Y");
set.add("X");
Iterator <String> it = set.iterator ();
int count = 0;
while (it.hasNext()) {
switch (it.next()){
case "X":
System.out.print("X ");
break;
case "Y":
System.out.print("Y ");
break;
}
count++;
}
System.out.println ("\ncount = " + count);
}
}
What is the result?
Given:
import java.util.*;
public class StringApp {
public static void main (String [] args) {
Set <String> set = new TreeSet <> ();
set.add("X");
set.add("Y");
set.add("X");
set.add("Y");
set.add("X");
Iterator <String> it = set.iterator ();
int count = 0;
while (it.hasNext()) {
switch (it.next()){
case "X":
System.out.print("X ");
break;
case "Y":
System.out.print("Y ");
break;
}
count++;
}
System.out.println ("\ncount = " + count);
}
}
What is the result?
정답: D
설명: (KoreaDumps 회원만 볼 수 있음)