1Z0-829 · topic practice

Utilizing Java Object-Oriented Approach practice questions

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.

Courseiva uses original exam-style practice questions designed for learning and revision. The goal is to understand the concepts, recognise exam patterns, and improve through explanations — not memorise copied exam dumps.

Reviewed byJohnson Ajibi· MSc IT Security
20 questionsDomain: Utilizing Java Object-Oriented Approach

What the exam tests

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.

Practice set

Utilizing Java Object-Oriented Approach questions

20 questions · select your answer, then reveal the explanation

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

Exhibit

Refer to the exhibit.

public class Main {
    public static void main(String[] args) {
        System.out.println("Hello");
    }
}

And the command:

$ javac Main.java
$ java Main

Output:
Hello

Now consider this class in another file:

public class Sub extends Main {
    public static void main(String[] args) {
        System.out.println("World");
    }
}

Compiled and run:

$ java Sub

What is the output?

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

Question 3easymultiple choice
Read the full NAT/PAT explanation →

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?

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

Drag steps to the numbered slots on the right, or tap a step then tap a slot.

Steps
Order
1Step 1
2Step 2
3Step 3
4Step 4
5Step 5

Match each functional interface to its abstract method signature.

Drag a concept onto its matching description — or click a concept then click the description.

Concepts
Matches

T get()

void accept(T t)

R apply(T t)

boolean test(T t)

T apply(T t)

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

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?

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

Question 9mediummultiple choice
Read the full NAT/PAT explanation →

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

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

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

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

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

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

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

Given the exhibit, what is a key difference between a materialized view and a regular view?

Exhibit

Refer to the exhibit.

```
-- SQL to create table
CREATE TABLE departments (
    dept_id INT PRIMARY KEY,
    dept_name VARCHAR(50)
);

-- Materialized view with refresh
CREATE MATERIALIZED VIEW dept_summary
REFRESH COMPLETE ON DEMAND
AS
SELECT dept_id, COUNT(*) AS emp_count
FROM employees
GROUP BY dept_id;

-- Query
SELECT * FROM dept_summary;
```

Given the exhibit, which statement about calling this function in a SELECT statement is true?

Exhibit

Refer to the exhibit.

```
-- Creating a PL/SQL function
CREATE OR REPLACE FUNCTION get_emp_name (p_emp_id NUMBER) RETURN VARCHAR2 IS
    v_name employees.last_name%TYPE;
BEGIN
    SELECT last_name INTO v_name FROM employees WHERE employee_id = p_emp_id;
    RETURN v_name;
END;
```

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?

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

Which statement about the code is correct?

Exhibit

Refer to the exhibit.

sealed class Shape permits Circle, Square {
    abstract double area();
}

final class Circle extends Shape {
    double area() { return 0; }
}

non-sealed class Square extends Shape {
    double area() { return 0; }
}

class Triangle extends Shape { }

Free account

Track your progress over time

Create a free account to save your results and see which topics improve across sessions.

Focused Utilizing Java Object-Oriented Approach sessions

Start a Utilizing Java Object-Oriented Approach only practice session

Every question in these sessions is drawn from the Utilizing Java Object-Oriented Approach domain — nothing else.

Related practice questions

Related 1Z0-829 topic practice pages

Move into related areas when this topic feels solid.

Frequently asked questions

What does the 1Z0-829 exam test 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 should I use these practice questions?
Select your answer before revealing the explanation. Then read why each option is right or wrong — this active recall approach builds retention far faster than re-reading notes.
Can I practise just Utilizing Java Object-Oriented Approach questions in a focused session?
Yes — the session launcher on this page draws every question from the Utilizing Java Object-Oriented Approach domain. Use a 10-question session first to gauge your baseline, then move to 20 or 30 once the weak spots are clear.
Where can I practise other 1Z0-829 topics?
Use the topic links above to move to related areas, or go back to the 1Z0-829 question bank to see all topics.
Are these real exam questions or dumps?
These are original practice questions written to test the same concepts the 1Z0-829 exam covers. They are not copied from any real exam or dump site.