JAVA PROGRAMMING TENTH EDITION COMPREHENSIVE EXAMINATION TEST 2026 CERTIFICATION EVALUATIO, Exams of Java Programming

JAVA PROGRAMMING TENTH EDITION COMPREHENSIVE EXAMINATION TEST 2026 CERTIFICATION EVALUATION CODING LOGIC PRACTICE BANK

Typology: Exams

2025/2026

Available from 05/22/2026

Professor_Beatrice
Professor_Beatrice ๐Ÿ‡บ๐Ÿ‡ธ

5

(1)

49K documents

1 / 22

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
JAVA PROGRAMMING TENTH EDITION
COMPREHENSIVE EXAMINATION TEST
2026 CERTIFICATION EVALUATION
CODING LOGIC PRACTICE BANK
โ—‰ ________ is not an object-oriented programming language.
A. Java
B. C++
C. C
D. C#
E. Python
Answer: C. C
โ—‰ ________ is interpreted.
A. Java
B. C++
C. C
D. Ada
E. Pascal
Answer: A. Java
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff
pf12
pf13
pf14
pf15
pf16

Partial preview of the text

Download JAVA PROGRAMMING TENTH EDITION COMPREHENSIVE EXAMINATION TEST 2026 CERTIFICATION EVALUATIO and more Exams Java Programming in PDF only on Docsity!

JAVA PROGRAMMING TENTH EDITION

COMPREHENSIVE EXAMINATION TEST

2026 CERTIFICATION EVALUATION

CODING LOGIC PRACTICE BANK

โ—‰ ________ is not an object-oriented programming language. A. Java B. C++ C. C D. C# E. Python Answer: C. C โ—‰ ________ is interpreted. A. Java B. C++ C. C D. Ada E. Pascal Answer: A. Java

โ—‰ ________ is architecture-neutral. A. Java B. C++ C. C D. Ada E. Pascal Answer: A. Java โ—‰ ________ is a technical definition of the language that includes the syntax and semantics of the Java programming language. A. Java language specification B. Java API C. Java JDK D. Java IDE Answer: A. Java language specification โ—‰ ________ contains predefined classes and interfaces for developing Java programs. A. Java language specification B. Java API C. Java JDK D. Java IDE

B. public static void Main(String[] args) C. public static void main(String[] args) D. public static main(String[] args) E. public void main(String[] args) Answer: C. public static void main(String[] args) โ—‰ Which of the following statements is correct? A. Every line in a program must end with a semicolon. B. Every statement in a program must end with a semicolon. C. Every comment line must end with a semicolon. D. Every method must end with a semicolon. E. Every class must end with a semicolon. Answer: B. Every statement in a program must end with a semicolon. โ—‰ Which of the following statements is correct to display Welcome to Java on the console? A. System.out.println('Welcome to Java'); B. System.out.println("Welcome to Java"); C. System.println('Welcome to Java'); D. System.out.println('Welcome to Java"); E. System.out.println("Welcome to Java');

Answer: B. System.out.println("Welcome to Java"); โ—‰ The JDK command to compile a class in the file Test.java is A. java Test B. java Test.java C. javac Test.java D. javac Test E. JAVAC Test.java Answer: C. javac Test.java โ—‰ Which JDK command is correct to run a Java application in ByteCode.class? A. java ByteCode B. java ByteCode.class C. javac ByteCode.java D. javac ByteCode E. JAVAC ByteCode Answer: A. java ByteCode โ—‰ Java compiler translates Java source code into _________. A. Java bytecode B. machine code

Answer: D. Test.java โ—‰ The extension name of a Java bytecode file is A. .java B. .obj C. .class D. .exe Answer: C. .class โ—‰ The extension name of a Java source code file is A. .java B. .obj C. .class D. .exe Answer: A. .java โ—‰ Which of the following lines is not a Java comment? A. /** comments / B. // comments C. -- comments D. / comments */ E. ** comments **

Answer: C. -- comments E. ** comments ** โ—‰ Which of the following are the reserved words? A. public B. static C. void D. class Answer: A. public B. static C. void D. class โ—‰ Every statement in Java ends with ________. A. a semicolon (;) B. a comma (,) C. a period (.) D. an asterisk (*) Answer: A. a semicolon (;) โ—‰ A block is enclosed inside __________. A. parentheses

II:

public class Test { public static void main(String[] args) { System.out.println("Welcome to Java!"); } } A. Both I and II can compile and run and display Welcome to Java, but the code in II has a better style than I. B. Only the code in I can compile and run and display Welcome to Java. C. Only the code in II can compile and run and display Welcome to Java. D. Both I and II can compile and run and display Welcome to Java, but the code in I has a better style than II. Answer: D. Both I and II can compile and run and display Welcome to Java, but the code in I has a better style than II. โ—‰ Which of the following code has the best style? I: public class Test { public static void main(String[] args) { System.out.println("Welcome to Java!"); } }

II:

public class Test { public static void main(String[] args) { System.out.println("Welcome to Java!"); } } III: public class Test { public static void main(String[] args) { System.out.println("Welcome to Java!"); } } IV: public class Test { public static void main(String[] args) { System.out.println("Welcome to Java!"); } } A. I B. II

The clock speed of a computer is usually stated in megahertz (MHz) (1 MHz is 1 million Hz). โ—‰ What is a bit? What is a byte? Answer: A bit is a binary digit 0 or 1. A byte is a sequence of 8 bits. โ—‰ What is memory for? What does RAM stand for? Why is memory called RAM? Answer: Memory is like a work area for programs. Before a program is executed, it is brought into the memory. RAM stands for random- access memory. It is called RAM because a memory cell can be accessed directly. โ—‰ What unit is used to measure memory size? What unit is used to measure disk size? Answer: Memory size is measured in bytes. Disk size is measured in bytes. โ—‰ What is the primary difference between memory and a storage device? Answer: Memory is volatile, because information is lost when the power is turned off. Programs and data are permanently stored on storage devices and are moved, when the computer actually uses them, to memory, which is much faster than storage devices.

โ—‰ What language does the CPU understand? Answer: The machine language is a set of primitive instructions built into every computer. This is the language understood by a computer and executed by a computer. โ—‰ What is an assembly language? What is an assembler? Answer: Assembly language is a low-level programming language in which a mnemonic is used to represent each of the machine language instructions. Assembler is a software that translates assembly language into machine language. โ—‰ What is a high-level programming language? What is a source program? Answer: The high-level languages are English-like and easy to learn and program. The program written in a programming language is called a source program. โ—‰ What is an interpreter? What is a compiler? Answer: An interpreter is a software that reads one statement from the source code, translates it to the machine code or virtual machine code, and then executes it right away.

โ—‰ What is multiprogramming? Answer: Multiprogramming allows multiple programs to run simultaneously by sharing the CPU. โ—‰ What is multithreading? Answer: Multithreading allows concurrency within a program, so that its subtasks can run at the same time. โ—‰ What is multiprocessing? Answer: Multiprocessing, or parallel processing, uses two or more processors together to perform a task. โ—‰ Who invented Java? Which company owns Java now? Answer: Java was invented by a team led by James Gosling at Sun Microsystems in 1991. Originally called Oak, it became Java in 1995 when it was redesigned for developing Internet applications. Oracle bought Sun and Oracle now owns Java. โ—‰ What is a Java applet? Answer: Java applet is a special program that runs from a Web browser. Due to security reasons, applets are no longer allowed to run from Web browsers.

โ—‰ What programming language does Android use? Answer: Android uses the Java programming language. โ—‰ What is the Java language specification? Answer: The Java language specification specifies the syntax for the Java language. โ—‰ What does JDK stand for? What does JRE stand for? Answer: JDK stands for Java Development Toolkit. JRE stands for Java Runtime Environment. โ—‰ What does IDE stand for? Answer: IDE stands integrated development environment. โ—‰ Are tools like NetBeans and Eclipse different languages from Java, or are they dialects or extensions of Java? Answer: NetBeans and Eclipse are not programming languages, nor dialects, nor extensions of Java. They are Java development tools. โ—‰ What is a keyword? List some Java keywords. Answer: Keywords have specific meaning to the compiler and cannot be used for other purposes in the program such as variables or method names. Examples of keywords are class, static, and void.

Answer: Output is 3.5 * 4 / 2 - 2.5 is

โ—‰ What is the Java source filename extension, and what is the Java bytecode filename extension? Answer: The source file extension is .java and the bytecode file extension is .class. โ—‰ What are the input and output of a Java compiler? Answer: The input of a Java compiler is a Java source code file and the output is a Java class file. โ—‰ What is the command to compile a Java program? Answer: javac is the JDK command to compile a program. โ—‰ What is the command to run a Java program? Answer: java is the JDK command to run a program. โ—‰ What is the JVM?

Answer: JVM is the Java virtual machine that runs a Java program. โ—‰ Can Java run on any machine? What is needed to run Java on a computer? Answer: Java can run on any machine with a JVM. โ—‰ If a NoClassDefFoundError occurs when you run a program, what is the cause of the error? Answer: Java interpreter cannot find the .class file. Make sure you placed the file in the right place, and invoked java command with appropriate package name. โ—‰ If a NoSuchMethodError occurs when you run a program, what is the cause of the error? Answer: The class does not have a main method, or the signature of the main method is incorrect. โ—‰ Reformat the following program according to the programming style and documentation guidelines. Use the end-of-line brace style. public class Test { // Main method public static void main(String[] args) { /** Display output */