Update task3.py

By putting the main guts of this program into its own function we can write a test routine that will test the ISBN number