Wednesday, November 19, 2025, last 60 minutes of class.
Labs 8–16, and all the associated readings in the Further Study sections.
In person. It is a GROUP EXAM! Y’all take it together.
Do each of the following to maximize your preparation:
Were you able to check off every box?
The fact that active recall is better for acquiring long-term knowledge does not mean that outlines and concept maps are not useful. Learners should use multiple techniques—think “both and” rather than “either or.”
Recursion
base case
recursive case
often you don’t need or want it, if a simple loop will do
if recursion is multi-way, it tends to shine more
(but be careful not to “overlap”—you will learn why in CMSI 2120)
recursion in nature and art (Fractals)
Classes
often better than dictionaries when representing ”things”
class definitions
__init__() method
self parameter
attributes
methods
Variables are necessary for sharing!
Dataclass are usually better! (__init__() is auto-generated)
Have to use the @dataclass decorator
Have to import dataclass from the dataclasses module
You can validate with __post_init__()
RGB Colors
RGB tuples
(0, 0, 0) is black
(255, 255, 255) is white
(255, 0, 0) is red
(0, 255, 0) is green
(0, 0, 255) is blue
other colors are combinations of red, green, and blue
Pygame
pygame.init()
pygame.display.set_mode()
pygame.display.set_caption()
Event loop
raise SystemExit after QUIT event and pygame.quit()
pygame.event.get()
Event types like QUIT, KEYDOWN, KEYUP, MOUSEBUTTONDOWN, MOUSEBUTTONUP
pygame.draw.rect()
pygame.draw.circle()
pygame.draw.line()
pygame.draw.polygon()
pygame.draw.arc()
pygame.draw.ellipse()
pygame.display.flip()
Colors as RGB tuples
clock = pygame.time.Clock() and clock.tick(60) for smooth animation
Keyboard events
Collision detection
Custom events
You will be presented with the problems and you will work together as a class to produce answers on the whiteboard.
There will be 10 questions, each of which will be writing little snippets of code.