Nov 10
(The program that we worked on in class,
cards_nov10.py, is attached.)
poker assignment
Discuss and go over classes for Card, Deck, Hand, PokerHand.
This is one of most complicated tasks we'll do this semester - don't be shy about asking questions. (I didn't warn you that this one was "hard" ... hopefully it was a learning experience, however far you got.)
How do we look for things like "straights" or "three of a kind"? Well, there are many approaches, some with lots and lots of "if" statements, and some that analyze the hand with loops and new data structures.
Volunteers to discuss your work?
Here are my versions ... which we'll discuss in class.
what's coming next
It's time for you to start thinking about a final term project -
a project of your choice that will illustrate your understanding
of the topics we've covered this semester.
Next week's homework assignment is to propose something.
The homework over the weeks following will be less,
to give you time to work on the projects. Please do
use that time wisely - talk to Sam, get small version(s)
working right away, and so on.
We will have a day of class presentations of these projects.
Here are some ideas to consider.
- a "text adventure" game
- an graphics project using Zelle's library such as
- drawing a fractal
- drawing a maze
- drawing some sort of art, perhaps using random numbers
- a graphical game like "pong" or "space invaders"
- some sort of word search or puzzle, such Boggle
- a sound/music project using a python music library
- a python extension within an existing software application such as
- some project euler problems
- doing something with the micropython board (access permitting)
- exploring a python library, such as one of these
- ... anything inspired by a homework problem or demo this term
In the weeks between now and the end of term, we'll be looking
some of these possibilities, and exploring a few other topics
(recursion, searching game move trees).