These are snippets of Python code with results that you may find surprising, especially if you're new to Python.
- gotchas: these sometimes bite new Python programmers. The most useful sort of oddity to discuss.
- Example: mutable default function arguments
- curiosities: a peculiarity that's unexpected, but not something you'd care about day-to-day
- Example:
-5to256are always identical but other numbers aren't
- Example:
- absurdities: absurd code, just for the fun of it
- example:
{*()}vs.set()
- example: