Given the code fragment: Path path1 = Paths.get(“/app/./sys/”); Path res1 = path1.resolve(“log”); Path path2 = Paths.get(“/server/exe/”); Path res1 = path1.resolve(“/readme/”); System.out.println(res1); System.out.println(res2); What is the result? A. /app/sys/log /readme/server/exe B. /app/log/sys /server/exe/readme C. /app/./sys/log /readme D. /app/./sys/log /server/exe/readme

Given the code fragment: What is the result? A. Searching… B. Searching… Searching… C. Searching… Searching… Searching… D. A compilation error occurs.

Given: What is the result? A. User is registered. B. An AgeOutOfLimitException is thrown. C. A UserException is thrown. D. A compilation error occurs in the main method.

Given: What is the result? A. Read Java Programming View http:/ ebook.com/ebook B. Read Java Programming Read http:/ ebook.com/ebook C. The EBook.java file fails to compile. D. The Test.java file fails to compile.

Given the code fragment: ZonedDateTime depart = ZonedDateTime.of(2015, 1, 15, 3, 0, 0, 0, ZoneID.of(“UTC-7”)); ZonedDateTime arrive = ZonedDateTime.of(2015, 1, 15, 9, 0, 0, 0, ZoneID.of(“UTC-5”)); long hrs = ChronoUnit.HOURS.between(depart, arrive); //line n1 System.out.println(“Travel time is” + hrs + “hours”);…

Given the code fragment: Assume that the ready method of the BufferedReader, when called on a closed BufferedReader, throws an exception, and employee.txt is accessible and contains valid text. What is the result? A. A compilation error occurs at line…

Given that /green.txt and /colors/yellow.txt are accessible, and the code fragment: Path source = Paths.get(“/green.txt); Path target = Paths.get(“/colors/yellow.txt); Files.move(source, target, StandardCopyOption.ATOMIC_MOVE); Files.delete(source); Which statement is true? A. The green.txt file content is replaced by the yellow.txt file content and…

Given: interface Doable { public void doSomething (String s); } Which two class definitions compile? A. public abstract class Task implements Doable { public void doSomethingElse(String s) { } } B. public abstract class Work implements Doable { public abstract…

Given the code fragment: Which statement is true? A. The program prints Call Call and terminates. B. The program prints Call Call and does not terminate. C. A compilation error occurs at line n1. D. An ExecutionException is thrown at…