COET 3 Group Assignment 2
COET 3 Group Assignment 2
1. Introduction to Exceptions
Try Block: Explain the purpose of the try block and what types of code it
should contain (e.g., code that might throw exceptions).
Catch Block: Describe the catch block and how it is used to handle
exceptions that occur in the try block.
Multiple Catch Blocks: Explain how multiple catch blocks can be used
to handle different types of exceptions.
Exception Matching: Discuss how C++ matches the thrown exception
to the appropriate catch block.
Provide an example that demonstrates using multiple catch blocks to
handle different types of exceptions.
Syntax and Usage: Explain the throw statement and how it is used to
throw exceptions in C++.
Types of Objects: Discuss the different types of objects that can be
thrown (such as integers, strings, and user-defined objects).
Exception Propagation: Explain how exceptions are passed from the
try block to the catch block using throw.
Provide an example where a function throws an exception if an invalid
input is provided.
7. Stack Unwinding
Submission Guidelines: