Challenges


  1. Improve the function ask_number() so that the function can be called with a step value. Make the default value of step 1.

  2. Modify the Guess My Number chapter project from Chapter 3 by reusing the function ask_number().

  3. Modify the new version of Guess My Number you created in the last challenge so that the program's code is in a function called main(). Don't forget to call main() so that you can play the game.

  4. Write a new computer_move() function for the Tic-Tac-Toe game to plug the hole in the computer's strategy. See if you can create an opponent that is unbeatable!




Python Programming for the Absolute Beginner
Python Programming for the Absolute Beginner, 3rd Edition
ISBN: 1435455002
EAN: 2147483647
Year: 2003
Pages: 194

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net