#!/usr/bin/env python # coding: utf-8 # #Errors and Exceptions Homework - # ###Problem 1 # Handle the exception thrown by the code below by using try and except blocks. # In[1]: for i in ['a','b','c']: print i**2 # ###Problem 2 # Handle the exception thrown by the code below by using **try** and **except** blocks. Then use a **finally** block to print 'All Done.' # In[2]: x = 5 y = 0 z = x/y # ###Problem 3 # Write a function that asks for an integer and prints the square of it. Use a while loop with a try,except, else block to account for incorrect inputs. # In[24]: def ask(): pass() # In[25]: ask() # #Great Job!