Made the output of play_game() a bit more verbose#156
Made the output of play_game() a bit more verbose#156norvig merged 3 commits intoaimacode:masteraimacode/aima-python:masterfrom
Conversation
|
@SnShine, it makes little sense to remove the outputs from the notebooks. We cannot predict how the readers plan to use these IPython Notebooks. There will be quite a few readers who won't install the necessary apps to download and run the Notebooks, and will just prefer reading them online in their browsers. Also, these notebooks are very portable and can to converted to a variety of formats, including static HTML pages, Latex documents, Python code and whatnot. A reader not interactively running these notebooks will then, be able to make little use of them. |
|
I always think it is good to have notebooks free from outputs so user can run them and learn from them while doing so. But it would make easier to people to convert notebooks to other formats if there are outputs in the notebooks. Viewing notebooks online would surely requires outputs to be present. |
|
I think we should generate and store notebooks with all output. Then, a user (or we) can clear the output for use when we know an interactive notebook is available. I think there can be more than one "human" player -- one that produces moves by typing input, and one that clicks. |
Made the output of play_game() a bit more verbose
Changes:
And @norvig, I am trying to implement interactive TicTacToe game in notebooks. In our
query_player()function, we haveinput()which takes the input move from the player. Shall we change the way how we take the input from user? Because in notebooks, we need to take input as on_click_event() on any object and state shouldn't be displayed as it is displaying now viagame.display(state). Or shall I implement another method if we are running the game from inside notebooks. In the later case we can play the game both in command line and in notebooks (interactively!). Need your inputs here.