OH BOY OH BOY OH FU

Ace your homework & exams now with Quizwiz!

Which of the following can be used as a wildcard to represent a single character in SQL?

(*)

You can declare an enumerated data type inside of a method. (True/False)

False

Shadowing is the term used to describe where the field name is hidden by the name of a local or parameter variable. (True/False)

True

When an object reference is passed to a method, the method may change the values in the object. (True/False)

True

The ________ is at least one case in which a problem can be solved without recursion.

base case

A method that calls itself is a ________ method.

recursive

To add padding to an HBox you can call the _______ method.

setPadding

If you write a toString method to display the contents of an object, object1, for a class, Class1, then the following two statements are equivalent: System.out.println(object1); System.out.println(object1.toString()); (True/False)

True

If a method does not handle a possible checked exception, what must the method have?

A throws clause in its header

To create a TextField control, you use the _________, class which is in the ________ package.

TextField, javafx.scene.control

A compiler error will result if an anonymous inner class tries to use a variable that is not final or not effectively final. (True/False)

True

A method that stores a value in a class's field or in some other way changes the value of a field is known as a mutator method. (True/False)

True

An enumerated data type is actually a special type of class. (True/False)

True

Assuming three ImageView objects named puppy, kitten, and bunny have been created, what does the following statement do?HBox hbox = new HBox(5, puppy, kitten, bunny);

There will be five pixels of space between the controls horizontally in the container.

Every class has a toString method and an equals method inherited from the Object class. (True/False)

True

If a class has a method named finalize, it is called automatically just before an instance of the class is destroyed by the garbage collector. (True/False)

True

Given the following constructor code, which of the statements are true? public Book(String ISBNOfBook, double priceOfBook,int numberOrderedOfBook){ if (ISBNOfBook == "")throw new BlankISBN();if (priceOfBook < 0)throw new NegativePrice(priceOfBook);if (numberedOrderedOfBook < 0)throw new NegativeNumberOrdered(numberOrderedv);ISBN = ISBNOfBook;price = priceOfBook;numberedOrdered = numberOrderedOfBook;}

All of the above

Which of the following problems can be solved recursively?

All of these

An action that takes place while a program is running is a(n) _________.

An event handler

The term "default constructor" is applied to the first constructor written by the author of the class. (True/False)

False

When a local variable in an instance method has the same name as an instance field, the instance field hides the local variable. (True/False)

False

All exceptions are instances of classes that extend this class.

Throwable

What string lists the protocol that should be used to access a database, the name of the database, and potentially other items?

Database URL

In a recursive program, the number of times a method calls itself is known as the ________.

Depth of recursion

A(n) __________ is a section of code gracefully responds to exceptions when they are thrown

Exception handler

All methods in an abstract class must also be declared abstract. (True/False)

False

________ refers to data that describes other data

Metadata

A(n) ________ is an action that takes place in an application, such as clicking a button.

event

Which of the following is the Statement interface method that should be used to execute an INSERT statement?

executeUpdate

The actions performed by the JVM that takes place with each method call are sometimes referred to as ________.

overhead

An object can store data. (True/False)

True

________ occurs when method A calls method B which in turn calls method A

indirect recursion

Given the following code that uses recursion to find the factorial of a number, how many times will the else clause be executed if n = 5? private static int factorial(int n) { if (n == 0) return 1; else return n * factorial (n - 1); }

5

A method is called from the main method for the first time. It then calls itself seven times. What is the depth of recursion?

7

A single copy of a class's static field is a shared by all instances of the class. (True/False)

True

An abstract class is not instantiated itself but serves as a superclass for other classes. (True/False)

True

An instance of a class does not have to exist in order for values to be stored in a class's static fields. (True/False)

True

Because the subclass is more specialized than the superclass, it is something necessary for the subclass to replace inadequate superclass methods with more suitable ones. (True/False)

True

The key word this is the name of a reference variable that an object can use to refer itself. (True/False)

True

Classes that inherit from the Error class are for exceptions that are thrown when

a critical error occurs, and the application program should not try to handle them.

If you set a scene's size to a width and height that is smaller than the width and height of the image to be displayed _______.

only part of the image will be displayed

In a try/catch construct, after the catch statement is executed ________.

the program resumes at the statement that immediately follows the try/catch construct.

A(n) __________ contains one or more statements that are executed can potentially throw an exception

try block

It is not possible for a superclass to a call a subclass's method. (True/False)

False

The key word this is the name of a reference variable that is available to all static methods. (True/False)

False

The ________ layout container arranges the contents into cells, similar to a spreadsheet.

GridePane

The ______ statement is used in SQL to insert a new row into a table.

INSERT

In an entity relationship diagram the primary key is denoted with ________.

PK

What is the default concurrency level of a ResultSet object?

Read-only

The __________ type of SQL statement is used to retrieve the rows from a table.

SELECT


Related study sets

Last names (Apellidos) customs in the Hispanic world

View Set

Food & Nutrition Unit 6: Water, Vitamins, & Minerals

View Set

AP AMERICAN GOVERNMENT CHAPTER 11

View Set

9.01 Homework Quiz: Moral and Cultural Differences in America

View Set