Very good attempt at the homework - well done for adding error checking in. Take care of indentation at all times (lines 22 & 23).