try:
# The code that exceptions can be caused
# ...
except Exception1 as e:
# Exception1
# ...
except Exception2 as e:
# Exception2
# ...
except Exception3 as e:
# Exception3
# ...
try:
# The code that exceptions can be caused
# ...
except (Exception1, Exception2, Exception3) as e:
# When it occurs
# ...