A Simple Game
Rock Paper Scissors. Coding on the fly! Easy to impress 11 year olds!
The group was a bit smaller this time, we were competing against a basketball game (and pizza) so this was not surprising. The plan for this time was to do a little bit of something together around a piece of code I already have on-hand, and then to end the session with Code Academy. Plus, we were ready with a projector remote.
In Practice
This time it went better. We did some post-it work on the wall to work out the logic of Rock Paper Scissors. Given our choice, what would happen if the computer chose Rock? What about Scissors? And Paper? It looked something like this:
And then we tried out the code I brought. And in particular, looked at this section and compared it to our post it note logic, checking off each condition as we went (below)
Then they wanted to change the code slightly to play against each other. Which we did, and it was great.
In the End
This time things were much smoother. “You made this?” they asked. Which was the best. Plus, this was an easy to understand example. They could get it. Much better choice over logic problems.
