Except with empty tuple

Antoon Pardon antoon.pardon at vub.be
Wed Oct 16 10:03:12 EDT 2019


I would like to verify I understand correctly.

It is about the following construct:

    try:
        statement1
        statement2
        ...
    except ():
        pass

As far as I understand and my tests seem to confirm this, this
is equivallent to just

    statement1
    statement2
    ...

Am I correct or did I miss something?

-- 
Antoon.




More information about the Python-list mailing list