Courseiva

1Z0-829 · domain

Utilizing Java Object-Oriented Approach

Practise Oracle Certified Professional Java SE 17 Developer 1Z0-829 Utilizing Java Object-Oriented Approach practice questions — original exam-style scenarios with answer choices, explanations, and analysis of common mistakes.

31 questions5 easy12 medium14 hard

Focused practice

Practice Utilizing Java Object-Oriented Approach questions

Scored sessions drawing only from this domain — pick a length below.

Start 20-question practice test →

What this domain covers

What to know about Utilizing Java Object-Oriented Approach

Utilizing Java Object-Oriented Approach questions test whether you can apply the concept in context, not just recognise a definition.

How the topic appears in realistic exam-style scenarios.

Which detail in the question changes the correct answer.

How to eliminate plausible but wrong options.

How to connect the question back to the wider exam objective.

Watch out for

Common Utilizing Java Object-Oriented Approach exam traps

  • Answering from memory before reading the full scenario.
  • Missing a constraint such as cost, availability, security, scope or command context.
  • Choosing a broad answer when the question asks for the most specific fix.
  • Ignoring why the wrong options are tempting.

Question index

All Utilizing Java Object-Oriented Approach questions (31)

Click any question to see the full explanation, or start a practice session above.

1

Refer to the exhibit. What is the result of compiling and running the Test class?

Hard
2

Refer to the exhibit. What is the result of compiling and running the Main class?

Medium
3

Refer to the exhibit. What is the output?

Medium
4

Given a record `Point(int x, int y)`, which statement is true about the automatically generated constructor?

Hard
5

Arrange the steps to override equals() and hashCode() correctly in Java.

Medium
6

Match each functional interface to its abstract method signature.

Medium
7

Which two statements are true about records in Java? (Choose two.)

Medium
8

You are designing a logging framework for a distributed application. The framework must support multiple output destinations (console, file, network socket) and allow clients to dynamically add new destinations at runtime without modifying existing code. Currently, the application uses a single static Logger class with methods like logToConsole(String msg) and logToFile(String msg). The team needs to refactor the code to adhere to the Open/Closed Principle and support extensibility. After reviewing the requirements, you propose using a combination of an interface and a strategy pattern. However, a senior developer argues that using a simple enum with abstract methods would be sufficient. Which course of action best adheres to object-oriented design principles and allows the most flexibility for future extensions?

Easy
9

Which statement about the code is correct?

Hard
10

Which TWO access modifiers can be applied to a top-level class in Java? (Choose two.)

Easy
11

A class `Transaction` is declared as `sealed`. Which statement correctly implements a permitted subclass?

Hard
12

Refer to the exhibit. What is the output?

Hard
13

Given the exhibit, which statement about calling this method is true?

Medium
14

Refer to the exhibit. What is the output?

Hard
15

Refer to the exhibit. Given the following code: ```java 1: sealed interface Shape permits Circle { } ... 10: class Circle implements Shape { } ``` What is the result?

Medium
16

Refer to the exhibit. What is the result?

Hard
17

Refer to the exhibit. Which statement about this Singleton implementation is correct?

Hard
18

A class `Account` has a method `public void deposit(double amount)`. Which approach correctly demonstrates method overloading?

Easy
19

A financial services company runs a Java 17 Spring Boot application that processes real-time stock trades. The application uses a class `TradeProcessor` containing a method `void process(Trade trade)`. This method is invoked by multiple threads concurrently. The `Trade` class is immutable and has fields like `String symbol`, `int quantity`, `double price`. The `TradeProcessor` method updates a shared `HashMap<String, Double>` that tracks the average price per symbol. The update logic is: retrieve the current average for the symbol, compute a new average, and put it back. During high-load testing, the average prices are occasionally incorrect. The development team suspects a race condition. Which course of action should be taken to fix the issue with minimal performance impact?

Hard
20

Which design pattern is best suited for creating a family of related objects without specifying their concrete classes?

Medium
21

A developer needs to ensure that a class `Shape` cannot be instantiated but can be extended. Which modifier should be used?

Medium
22

Refer to the exhibit. What is the most direct way to fix the compilation error without changing the access modifier of the field?

Hard
23

Which TWO statements are true about the sealed class feature in Java 17?

Hard
24

Given the following code snippet: `List<Integer> list = new ArrayList<>(); list.add(10); list.add(20); list.remove(1); System.out.println(list);` What is the output?

Easy
25

What is a key difference between a class and an interface in Java?

Hard
26

You are designing a logging framework for a microservices application. The framework must support multiple output destinations (console, file, database) and allow new destinations to be added without modifying existing code. Additionally, each destination should be able to format the log message differently. The team prefers composition over inheritance. Which design pattern should you recommend?

Easy
27

A developer writes a class `Employee` with a private field `salary`. Which approach correctly allows subclasses to access `salary` directly without breaking encapsulation?

Medium
28

Which TWO statements about Java interfaces are true? (Choose two.)

Hard
29

Which THREE conditions must be true for a method to override another method in a subclass? (Choose three.)

Medium
30

Refer to the exhibit. Two Java classes are defined as shown. What is the output when the Sub class is executed?

Medium
31

Refer to the exhibit. What is the result?

Hard

Frequently asked questions

What does the Utilizing Java Object-Oriented Approach domain cover on the 1Z0-829 exam?
Utilizing Java Object-Oriented Approach questions test whether you can apply the concept in context, not just recognise a definition.
How many questions are in this domain?
This page lists all 31 Utilizing Java Object-Oriented Approach questions in the 1Z0-829 question bank. The actual exam draws from this domain proportionally to its weighting in the official exam blueprint.
What is the best way to practise this domain?
Start with a short focused session (10 questions) to identify gaps, then work through explanations. Repeat with a longer session once the weak areas feel solid.
Can I practise only Utilizing Java Object-Oriented Approach questions?
Yes — the session launcher on this page filters questions to this domain only. Choose any session length for inline explanations and scoring.
Oracle Certified Professional Java SE 17 Developer 1Z0-829 Utilizing Java Object-Oriented Approach Practice Questions