With functions and loops, the end of chapter 4 gets a bit tedious when you make a mistake.
I think it'd be beneficial to introduce the reader to typing the code in a text file and then executing it with python the_file.py.
This would also tie in better with the rest of the tutorial and show them that typing things in the shell or in a text file is basically the same.
To me, a good switching point might be right before introducing the print() function (whose utility is way more obvious when you run code from a file).
It would also allow us to format dictionaries with one key: value pair per line which might make things more clear.
With functions and loops, the end of chapter 4 gets a bit tedious when you make a mistake.
I think it'd be beneficial to introduce the reader to typing the code in a text file and then executing it with
python the_file.py.This would also tie in better with the rest of the tutorial and show them that typing things in the shell or in a text file is basically the same.
To me, a good switching point might be right before introducing the
print()function (whose utility is way more obvious when you run code from a file).It would also allow us to format dictionaries with one
key: valuepair per line which might make things more clear.