Java SE 7 Programmer I

Here you have the best Oracle 1z0-803 practice exam questions

  • You have 216 total questions to study from
  • Each page has 5 questions, making a total of 44 pages
  • You can navigate through the pages using the buttons at the bottom
  • This questions were last updated on October 20, 2025
  • This site is not affiliated with or endorsed by Oracle.
Question 1 of 216
Given the code fragment:
Exam 1z0-803: Question 1 - Image 1
What is the result?
    Correct Answer: D

Question 2 of 216
Given:
Exam 1z0-803: Question 2 - Image 1
What is the result?
    Correct Answer: A

    Within main, the local variable 'z' is assigned the value 6, which is then printed, leading to the output of 6. When 'doStuff()' is called, a new local variable 'z' is declared and assigned the value 5. The 'doStuff2()' method modifies the instance variable 'z' of the 'ScopeTest' class to 4. However, the local variable 'z' within 'doStuff()' remains 5, so the value 5 is printed next. Returning to 'main', the local 'z' still retains the value 6, which is printed once more. Lastly, 'myScope.z' is printed, which now holds the value 4 due to the 'doStuff2()' method. Thus, the final output is 6, 5, 6, 4.

Question 3 of 216
An unchecked exception occurs in a method dosomething()
Should other code be added in the dosomething() method for it to compile and execute?
    Correct Answer: D

Question 4 of 216
Given the code fragment:
Exam 1z0-803: Question 4 - Image 1
What is the result?
    Correct Answer: A

    The code first initializes the variable `b` to 4. The statement `b--` decreases the value of `b` by 1, changing it to 3. The statement `--b` is then executed, which decreases `b` by 1 again, changing it to 2, and this value is printed. Finally, the current value of `b`, which is now 2, is printed again. Therefore, the output is 2 and 2.

Question 5 of 216
Given the code fragment:
interface SampleClosable {
public void close () throws java.io.IOException;
}
Which three implementations are valid?
Exam 1z0-803: Question 5 - Image 1
    Correct Answer: A, C, E