# Module 20: Exception Handling

MODULE OVERVIEW

This module introduces exception handling in C++ programming and explains how
exceptions are used to manage errors and unexpected situations during program
execution.



Learners will explore different exception-handling classes, understand how try
and catch blocks are implemented, and learn how the throw keyword is used to
raise exceptions.



The module helps learners develop an understanding of error-handling techniques
in C++, enabling them to handle exceptional situations and improve the
reliability of their programs.






WHAT WILL BE COVERED


20.1 VARIOUS EXCEPTION HANDLING CLASSES

Explore different exception-handling classes in C++. Understand how exception
classes are used to represent and manage different types of errors and
exceptional conditions within a program.


20.2 IMPLEMENTING TRY AND CATCH BLOCK

Learn how try and catch blocks are implemented in C++ to handle exceptions.
Understand how code that may generate exceptions is placed within a try block
and how catch blocks handle exceptions when they occur.


20.3 USE OF THROW KEYWORD

Understand the use of the throw keyword in C++ and how it is used to raise
exceptions. Learn how exceptions can be generated and passed to
exception-handling mechanisms to manage unexpected situations during program
execution.


SKILLS YOU WILL GAIN

 * Understanding exception handling in C++.

 * Familiarity with exception-handling classes.

 * Implementing try and catch blocks.

 * Handling exceptions during program execution.

 * Using the throw keyword.

 * Managing exceptional conditions in C++ programs.


LEARNING OUTCOMES

By the end of this module, learners will be able to:

 * Explain the purpose of exception handling in C++.

 * Understand different exception-handling classes.

 * Implement try and catch blocks.

 * Identify and handle exceptions within a program.

 * Use the throw keyword to raise exceptions.

 * Apply basic exception-handling techniques to improve program reliability.


CERTIFICATION ALIGNMENT

This module develops error-handling and program reliability concepts that
support the development of robust C++ applications. The concepts covered
contribute to the programming knowledge learners build throughout the C and C++
training curriculum.





Explore More Programs [https://teamacademy.qa/collections/all-courses-1]