Added exercise iPython notebook, and some code changes