3 ms·
It uses printing to teach strings, format chars, escape sequences, variables, and calling functions. Glad to see my sneaky ways are working. :-)
by zedshaw 17y ago
It uses printing to teach strings, format chars, escape sequences, variables, and calling functions.
Glad to see my sneaky ways are working. :-)
- deleted 17y ago[deleted]
- mturmon 17y agoI think introducing some mystery of programming would be nice. The draft is very linear and predictable. How about a random number generator (linear RNGs are easy to code)? Or a line-by-line chaotic ascii art generator (like Wolfram's CA's)? Or, some other way to combine some of the string stuff with the arithmetic stuff. Also, I think python's + and * string operators are far cooler than the string escape sequences. A 6th or 7th grader would have mastered + and * for numbers, and the extension to strings might be interesting to them. Think of how cool some of the examples in SICP are as an inspiration. Simple, powerful, surprising. Not just type this, get that. The last page is nice, and insightful about the expanding future for using programming to advance another discipline. The bitterness at the end ("go to hell") was an off-taste.
- zedshaw 17y agoActually ascii art is in the works, but not yet. There will be a couple manual ones, but then the logic section will do more fun stuff. Remember, at the beginning the ready doesn't even know boolean logic, ifs, or looping yet. If you have ideas, throw them into the proposed exercises wiki: http://learnpythonthehardway.org/wiki?name=Proposed+Exercises http://learnpythonthehardway.org/wiki?name=Proposed+Exercise...