Key details for this exam, checked against the published exam outline
Each question shows the correct answer and an explanation of why it is right
Given the code fragments:

Which action prints Wagon : 200?
Assume you have an automatic module from the module path display-ascii-0.2. jar. Which name is given to the automatic module based on the given JAR file?
An automatic module name is derived from the name of the JAR file when it does not contain amodule-info.classfile. If the JAR file has an ''Automatic-Module-Name'' attribute in its main manifest, then its value is the module name. Otherwise, the module name is derived from the JAR file's name by removing any version numbers and converting it to lower case. Therefore, for a JAR nameddisplay-ascii-0.2.jar, the automatic module name would bedisplay-ascii, following these rules.
Given the code fragment:

Which two statements at Line nl independently enable you to print 1250?
Given the content of the in. tart file:
23456789
and the code fragment:

What is the content of the out .txt file?
The answer is D because the code fragment reads the content of the in.txt file and writes it to the out.txt file. The content of the in.txt file is ''23456789''. The code fragment uses a char array buffer of size 8 to read the content of the in.txt file. The while loop reads the content of the in.txt file and writes it to the out.txt file until the end of the file is reached. Therefore, the content of the out.txt file will be ''0123456789''.
Given:

What is the result?
Given the code fragment:

Which action sorts the book list?
Given the code fragment:

Which code line n1, obtains the java.io.Console object?
A)
![]()
B)
![]()
C)
![]()
D)
![]()
E)

The code fragment is trying to obtain the java.io.Console object, which is a class that provides methods to access the character-based console device, if any, associated with the current Java virtual machine. The correct way to obtain the Console object is to call the static method Console console() in the java.lang.System class. This method returns the unique Console object associated with the current Java virtual machine, if any. Therefore, option A is correct, as it calls System.console() and assigns it to a Console variable.Reference:
https://docs.oracle.com/javase/17/docs/api/java.base/java/io/Console.html
https://docs.oracle.com/javase/17/docs/api/java.base/java/lang/System.html#console()
https://education.oracle.com/products/trackp_OCPJSE17
https://mylearn.oracle.com/ou/learning-path/java-se-17-developer/99487
Exam domains verified against: Official Oracle 1Z0-829 exam guide, last checked October 2026.
Use primitives and wrapper classes including Math API, parentheses, type promotion, and casting to evaluate arithmetic and boolean expressions. Manipulate text including text blocks using String and StringBuilder classes, and manipulate date, time, duration, period, instant and time-zone objects using Date-Time API.
Sample question from this domain above: Q3
Create program flow control constructs including if/else, switch statements and expressions, loops, and break and continue statements.
Declare and instantiate Java objects including nested class objects and explain the object life-cycle. Create classes and records with instance and static fields, methods, constructors, and initializers. Implement inheritance, polymorphism, abstract and sealed classes, and use interfaces with private static and default methods.
Handle exceptions using try/catch/finally, try-with-resources, and multi-catch blocks including custom exceptions.
Create Java arrays, List, Set, Map, and Deque collections and add, remove, update, retrieve and sort their elements.
Sample question from this domain above: Q7
Use Java object and primitive streams including lambda expressions implementing functional interfaces to supply, filter, map, consume, and sort data. Perform decomposition, concatenation, reduction, grouping and partitioning on sequential and parallel streams.
Define modules and their dependencies exposing module content including for reflection. Define services, producers, and consumers. Compile Java code and produce modular and non-modular jars, runtime images, and implement migration using unnamed and automatic modules.
Create worker threads using Runnable and Callable and manage thread lifecycle including automations provided by different Executor services and concurrent API. Develop thread-safe code using different locking mechanisms and concurrent API. Process Java collections concurrently including parallel streams.
Read and write console and file data using I/O Streams. Serialize and de-serialize Java objects. Create, traverse, read, and write Path objects and their properties using java.nio.file API.
Sample question from this domain above: Q4
Create connections, create and execute basic, prepared and callable statements, process query results and control transactions using JDBC API.
Implement localization using locales, resource bundles, parse and format messages, dates, times, and numbers including currency and percentage values.
Common questions about the exam itself