Create 18.Exceptions 1

Python has an exception mechanism similar to Java. Exceptions are classes derived from Exception.The try/catch construct becomes try/except, and uses Python's indent grouping.This example catches several built-in exceptions. User-defined exceptions are quite possible, but we won't do that just yet.

Some exceptions provide an argument which describes it in more detail.Whether this exists, or what exactly it looks like, depends on the exception.