Tag Archives: Exam

Given the code fragment: (Exhibit) And given the requirements: 1. Process all the elements of the array

Given the code fragment:And given the requirements:1. Process all the elements of the array in the reverse order of entry.2. Process all the elements of the array in the order of entry.3. Process alternating elements of the array in the order of entry.Which two statements are true? (Choose two.) A. Requirement 2 can be implemented by using the… Read More »

In one of your databases, you create a user, HR, and then execute this command: GRANT CREATE SESSION

In one of your databases, you create a user, HR, and then execute this command:GRANT CREATE SESSION TO hr WITH ADMIN OPTION;Which three actions can HR perform? (Choose three.) A. Revoke the CREATE SESSION privilege from other users B. Revoke the CREATE SESSION privilege from user HR C. Log in to the database instance D. Grant the CREATE… Read More »

Given the code fragment: String name = "Spot"; int age = 4; String str ="My dog " + name + " is " + age;

Given the code fragment:String name = “Spot”;int age = 4;String str =”My dog ” + name + ” is ” + age;System.out.println(str);AndStringBuilder sb = new StringBuilder();Using StringBuilder, which code fragment is the best potion to build and print the followingstring My dog Spot is 4 A. sb.append(“My dog “).append( name ).append(” is ” ).append(age); System.out.println(sb); B. sb.insert(“My dog… Read More »

Examine the description of the SALES1 table: (Exhibit) SALES2 is a table with the same description as

Examine the description of the SALES1 table:SALES2 is a table with the same description as SALES1.Some sales data is duplicated in both tables.You want to display the rows from the SALES1 table which are not present in the SALES2 table.Which set operator generates the required output? A. UNION ALL B. MINUS C. INTERSECT D. UNION E. SUBTRACT Correct… Read More »

Given the code fragment: System.out.println(2 + 4 * 9 – 3); //Line 21 System.out.println((2 + 4) * 9

Given the code fragment:System.out.println(2 + 4 * 9 – 3); //Line 21 System.out.println((2 + 4) * 9 – 3); // Line 22 System.out.println(2 + (4 * 9) – 3); // Line 23 System.out.println(2 + 4 * (9 – 3)); // Line 24 System.out.println((2 + 4 * 9) – 3); // Line 25Which line of codes prints the highest… Read More »