一般的try语句形式如下:
try:
<语句>
except <异常名1>:
<语句>
except <异常名2>:
<语句>
else:
<语句>
>>> l=[1,2,3]
>>> try:
... l[5]
... except IndexError,Error:
... print Error
... else:
... print 'No Error'
...
list index out of range
>>> try:
... l[2]/0
... except(IndexError,ZeroDivisionError):
... print 'Error'
... else:
... print 'No Error'
...
Error