• Wrong document? Swap it for free
  • Written by students who passed
  • Immediately available after payment
  • Read online or as PDF
Sell
Where do you study
Your language
Document preview thumbnail
Preview 2 out of 5 pages
Exam (elaborations)

CS52 Chapter 16 – Quiz With Complete Solutions

Document preview thumbnail
Preview 2 out of 5 pages

CS52 Chapter 16 – Quiz With Complete Solutions...

Content preview

CS52 Chapter 16 – Quiz With Complete Solutions




The following function does not throw any unhandled exceptions void f1( )
throw ( ); - ANSWER TRUE

Functions that might throw an exception must have a throw list. - ANSWER
FALSE

Functions may potentially throw at most one exception. - ANSWER FALSE

If a function throws an exception, it must be caught inside that function. -
ANSWER FALSE

It is legal to have a catch block with no parameter. - ANSWER TRUE

In a try block, the throw statement is always executed. - ANSWER FALSE

The catch block is a function. - ANSWER FALSE

The braces are not necessary on a try block. - ANSWER FALSE

The throw statement passes a value to the catch block. - ANSWER TRUE

The catch block is the group of statements that handle an exception. -
ANSWER TRUE

Which of the following is not a valid reason for using exception handling? -
ANSWER throw and catch can be used like gotos

, The block of code that checks if an unusual situation or error occurs is
called - ANSWER the try block

The block of code that handles an exception is called - ANSWER the catch
block

When an unusual situation or error occurs, then the ________ statement is
executed. - ANSWER throw

A catch block that expects an integer argument will catch - ANSWER all
integer exceptions

When a throw statement is executed, - ANSWER execution of the try block
stops

The parameter in the catch statement - ANSWER identifies what type of
exceptions are caught

The throw statement is enclosed in - ANSWER a try block

A throw statement can throw

a. an integer exception

b. a float exception

c. a bool exception

d. an exception of any data type

e. all of the above

f. none of the above - ANSWER e. all of the above

The following catch statement
catch(...) - ANSWER catches all exceptions

The following class definition
class MyError
{}; - ANSWER has only a default constructor

Document information

Uploaded on
October 20, 2026
Number of pages
5
Written in
2026/2027
Type
Exam (elaborations)
Contains
Questions & answers
$15.49

Wrong document? Swap it for free Within 14 days of purchase and before downloading, you can choose a different document. You can simply spend the amount again.
Written by students who passed
Immediately available after payment
Read online or as PDF

Seller avatar
Reputation scores are based on the amount of documents a seller has sold for a fee and the reviews they have received for those documents. There are three levels: Bronze, Silver and Gold. The better the reputation, the more your can rely on the quality of the sellers work.
Zayla
3.2
(20)
Sold
160
Followers
13
Items
18300
Last sold
2 days ago



Why students choose Stuvia

Created by fellow students, verified by reviews

Quality you can trust: written by students who passed their tests and reviewed by others who've used these notes.

Didn't get what you expected? Choose another document

No worries! You can instantly pick a different document that better fits what you're looking for.

Pay as you like, start learning right away

No subscription, no commitments. Pay the way you're used to via credit card and download your PDF document instantly.

Student with book image

“Bought, downloaded, and aced it. It really can be that simple.”

Alisha Student

Working on your references?

Create accurate citations in APA, MLA and Harvard with our free citation generator.

Working on your references?

Frequently asked questions