<jupyter_start><jupyter_text>USING:     TRY, EXCEPT, & FINALLY<jupyter_code>### Create a list
sales = [6212, 717, 8216, 9218, 4520, 7856, 4312]<jupyter_output><empty_output><jupyter_text>TRY SOMETHING THAT DOESN'T WORK<jupyter_code># Try to add a list of integers and a string, if you get an error print out end program:
try:
    sales + 'A string of characters.'
except Exception as e:
    print('Oh No! We have an Error:', e)
finally:
    print('End Program')<jupyter_output>Oh No! We have an Error: can only concatenate list (not &quot;str&quot;) to list
End Program<jupyter_text>TRY SOMETHING THAT WORKS<jupyter_code># Try to print sales, print out the result & end program, if you get an error, print out error & end program:
try:
    print('Wow! It''s Worked!', sales)
# If you get an error, set the error as 'e',
except Exception as e:
    print('Error:', e)
finally:
    print('End program')<jupyter_output>Wow! Its Worked! [6212, 717, 8216, 9218, 4520, 7856, 4312]
End program