Given:
Acc.java:
Which statement is true?
Given the code fragment:
What is the result?
Which two array initialization statements are valid? (Choose two.)
Which is true about the switch statement?
Given:
What is the result?
Given the code fragment from three files:
Which code fragment, when inserted at line 2, enables the code to compile?
Given:
and the code fragment:
S2 sobj = new S2(); sobj.display(10, 100);
What is the result?
Given the code fragment:
What is the result?
Which three statements are true about the structure of a Java class? (Choose three.)
Given:
Which two code fragments can be inserted at line n1?
You are asked to develop a program for a shopping application, and you are given this information:
Which definition of the Toy class adds a valid layer of abstraction to the class hierarchy?
Given the definitions of the Bird class and the Peacock class:
and the code fragment:
Which code snippet can be inserted to print Fly.Dance. ?
Given this segment of code:
Which two statements, if either were true, would make the code compile? (Choose two.)
Given the code fragment:
What is the result?
Given the code fragment:
Which two modifications, when made independently, enable the code to print Joe:true: 100.0? (Choose two.)
Given the code fragment:
And given the requirements:
1. Process all the elements of the array in the order of entry.
2. Process all the elements of the array in the reverse order of entry.
3. Process alternating elements of the array in the order of entry.
Which two statements are true? (Choose two.)
Given:
What is the result?
Given the code fragment:
What is the result?
Given:
What is the result?
Given the code fragment:
What is the result?
Given:
Which action fixes the compiler error?
Given:
What is the result?
Given the definitions of the MyString class and the Test class:
What is the result?
Given:
What is the result?
Given these classes:
And given this main method:
Which two options compile when placed at line n1 of the main method? (Choose two.)
Given:
What is the result?
Given the code fragment:
Test.java:
Which is the result?
Given the code fragments:
Which modification enables the code to compile?
Given the code fragment:
What is the result?
Given the code fragment:
Which code fragment at line 10 prints Welcome 100?
Given these requirements:
Which set of actions meets the requirements with optimized code?
Given the code fragment:
What is the result?
Given:
And the code fragment:
Which code fragment, when inserted at line 14, enables the code to print Mike Found?
Given:
What is the result?
Which statement is true about the main() method?
Given the code fragment:
What is the result?
Examine the content of App.java:
Which is true?
Which two statements are true? (Choose two.)
Given the code fragment:
What is the result?
Given the code fragment:
Which modification enables the code fragment to print TrueDone?
Given:
What is the result?
Given this array:
Which two code fragments, independently, print each element in this array? (Choose two.)
Given the code fragment:
What is the result?
Given the code fragment:
What is the result?
Given the code fragment:
What is the result?
Given the code fragment:
What is the result?
Given the code fragment:
What is the result?
This grid shows the state of a 2D array:
The grid is created with this code:
Which line of code, when inserted in place of //line n1, adds an X into the grid so that the grid contains three consecutive Xs?
Given the code fragment:
Which two modifications should you make so that the code compiles successfully? (Choose two.)
Given the following code:
What is the output?
Given the code fragment:
What is the result?
Given:
Which code fragment should you use at line n1 to instantiate the dvd object successfully?
Given:
and the code fragment:
What is the result?
Given:
What is the result?
Given:
What is the result?
Given the code fragment:
What is the result?
Given the code fragment:
What is the result?
Given the code fragment:
What is the result?
Given the code fragment:
What is the result?
Given the code fragment:
Which modification enables the code to print 54321?
Given the definitions of the MyString class and the Test class:
What is the result?
Given:
And given the code fragment:
What is the result?
Which two are benefits of polymorphism? (Choose two.)
Given:
What is the result?
Given the code fragment:
What is the result?
Given the code fragment:
What is the result?
You are asked to create a method that accepts an array of integers and returns the highest value from that array.
Given the code fragment:
Which method signature do you use at line n1?