CSE 205 FINAL EXAM 2026 ACTUAL QUESTIONS AND
SOLUTIONS RATED A+
✔✔Which keyword is used in Java to define a class? - ✔✔class
✔✔Which of the following is not a kind of loop in Java? Choose all that apply. - ✔✔until
✔✔We cannot delete individual elements from an array in Java. - ✔✔true
✔✔An object and the variable that refers to it are two different things. - ✔✔true
✔✔All non-primitive types in Java are _____. - ✔✔reference types
✔✔operations are things an object _____. - ✔✔does
✔✔A name defined in an outer scope is not available in all blocks nested inside that
scope. - ✔✔false
✔✔Data hiding can allow us to separate the information from its representation. -
✔✔true
✔✔We can implement a getter method without a setter method, thus creating a read-
only value. - ✔✔true
✔✔Data hiding helps make encapsulation work. - ✔✔true
✔✔Responsibilities that are very closely related can and should generally be assigned
to a single class. - ✔✔true
✔✔In general, a setter method will take at least one argument. - ✔✔true
✔✔An object's operations are implemented as - ✔✔methods
✔✔An object's attributes are implemented as _ - ✔✔variables
✔✔In Java class members are declared with the keyword - ✔✔static
✔✔Creating an object of a class is called - ✔✔instaniation
✔✔In Java, a two dimensional array requires _____ indexes to access a specific
element. - ✔✔2
, ✔✔Java arrays have an attribute named _____ that can be accessed to get the size
(number of elements) of the array.
Group of answer choices - ✔✔length
✔✔Every Java program consists of at least one _____.
Group of answer choices - ✔✔System.out.println statement
variable declaration
while loop
Correct: none of these
condition
✔✔In Java a variable must ... - ✔✔none of these
✔✔Methods used to access an object's private data are called _ - ✔✔getters and
setters
✔✔Which object oriented element best allows us to designing and implementing
families of related types that share outward similarities, but have specialized behaviors?
- ✔✔Polymorphism
✔✔The benefit of data hiding is that we can make an object truly responsible for what it
knows and what it does. - ✔✔true
✔✔A variable of a primitive type can never be null. - ✔✔true
✔✔You cannot create sub-classes from abstract classes. - ✔✔false
✔✔If you declare a parameterized constructor in your class, the compiler will not create
default constructor for you. - ✔✔true
✔✔You can always use a sub-class object in place of a super class object. - ✔✔true
✔✔The "extends" keyword is not used to specify inheritance in Java. - ✔✔false
✔✔In Java, a two dimensional array in Java is really an "array of arrays".
Group of answer choices - ✔✔true
✔✔Method overloading distinguishes between methods based on _____.
Group of answer choices - ✔✔
✔✔In Java functions are called _____. - ✔✔methods
SOLUTIONS RATED A+
✔✔Which keyword is used in Java to define a class? - ✔✔class
✔✔Which of the following is not a kind of loop in Java? Choose all that apply. - ✔✔until
✔✔We cannot delete individual elements from an array in Java. - ✔✔true
✔✔An object and the variable that refers to it are two different things. - ✔✔true
✔✔All non-primitive types in Java are _____. - ✔✔reference types
✔✔operations are things an object _____. - ✔✔does
✔✔A name defined in an outer scope is not available in all blocks nested inside that
scope. - ✔✔false
✔✔Data hiding can allow us to separate the information from its representation. -
✔✔true
✔✔We can implement a getter method without a setter method, thus creating a read-
only value. - ✔✔true
✔✔Data hiding helps make encapsulation work. - ✔✔true
✔✔Responsibilities that are very closely related can and should generally be assigned
to a single class. - ✔✔true
✔✔In general, a setter method will take at least one argument. - ✔✔true
✔✔An object's operations are implemented as - ✔✔methods
✔✔An object's attributes are implemented as _ - ✔✔variables
✔✔In Java class members are declared with the keyword - ✔✔static
✔✔Creating an object of a class is called - ✔✔instaniation
✔✔In Java, a two dimensional array requires _____ indexes to access a specific
element. - ✔✔2
, ✔✔Java arrays have an attribute named _____ that can be accessed to get the size
(number of elements) of the array.
Group of answer choices - ✔✔length
✔✔Every Java program consists of at least one _____.
Group of answer choices - ✔✔System.out.println statement
variable declaration
while loop
Correct: none of these
condition
✔✔In Java a variable must ... - ✔✔none of these
✔✔Methods used to access an object's private data are called _ - ✔✔getters and
setters
✔✔Which object oriented element best allows us to designing and implementing
families of related types that share outward similarities, but have specialized behaviors?
- ✔✔Polymorphism
✔✔The benefit of data hiding is that we can make an object truly responsible for what it
knows and what it does. - ✔✔true
✔✔A variable of a primitive type can never be null. - ✔✔true
✔✔You cannot create sub-classes from abstract classes. - ✔✔false
✔✔If you declare a parameterized constructor in your class, the compiler will not create
default constructor for you. - ✔✔true
✔✔You can always use a sub-class object in place of a super class object. - ✔✔true
✔✔The "extends" keyword is not used to specify inheritance in Java. - ✔✔false
✔✔In Java, a two dimensional array in Java is really an "array of arrays".
Group of answer choices - ✔✔true
✔✔Method overloading distinguishes between methods based on _____.
Group of answer choices - ✔✔
✔✔In Java functions are called _____. - ✔✔methods