Programming · 5 modules

Python Fundamentals

The most-loved general-purpose language, explained from the ground up. Learn types and data structures, control flow, functions, OOP and the classic gotchas — and remember it with spaced repetition.

flashcards
80
flashcards
per day
~10 min
per day
level
Beginner
level
modules
5
modules
About this topic

What is Python?

Python is a general-purpose language famous for reading almost like plain English — and for being the lingua franca of data science, machine learning, automation and a huge share of backend development. Whether you are scripting a one-off task or building with LLMs, Python is usually the shortest path from idea to working code.

The fundamentals are where Python rewards precision. Knowing that a list is mutable and a tuple is not shapes how you model data; comprehensions and generators change how you write loops; and the classic gotchas — mutable default arguments, is vs ==, why 0.1 + 0.2 != 0.3 — stop being surprises and become things you simply know.

This track breaks the basics into five modules of bite-sized, practical questions — types and data structures, control flow and comprehensions, functions and scope, classes and OOP, and the idioms that make code Pythonic — and uses spaced repetition so the rules move from "I looked that up" to fluent recall.

What you'll learn

5 modules, seed to bloom

Each module is a set of flashcards — 80 in total. Answer, review, and watch your knowledge grow from seed to full bloom.

Types & Data Structures

Core built-in types — lists, tuples, dicts, sets, strings, and how mutability works

16 cards

Control Flow & Comprehensions

Conditionals, loops, comprehensions, exceptions, and pattern matching

16 cards

Functions & Scope

Defining functions — arguments, scope, closures, decorators, and generators

16 cards

Classes & OOP Basics

Classes, instances, inheritance, dunder methods, and Python's object model

16 cards

Idioms & Gotchas

Truthiness, common gotchas, and the idioms that make code Pythonic

16 cards
Try before you plant

Sample questions

A taste of the real flashcards. Pick an answer, then reveal the explanation.

Sample · Python Fundamentals

What does t[0] = 9 do when t is the tuple (1, 2, 3)?

  • ARaises TypeError — a tuple cannot be modified in place
  • BRebinds t to (9, 2, 3) — the tuple is copied on write
  • CNothing at all — item assignment on a tuple is a no-op
  • DReplaces element 0 in place — tuples resize but stay ordered
Permalink & share
Sample · Python Fundamentals

What does list(range(1, 10, 3)) return?

  • A[1, 4, 7] — the step advances by 3 and stops before 10
  • B[1, 4, 7, 10] — the stop value ends the sequence inclusively
  • C[1, 2, 3] — the third argument sets how many items to produce
  • D[3, 6, 9] — the step also decides where the sequence begins
Permalink & share
Sample · Python Fundamentals

f(v, acc=[]) appends v to acc. What does f(2) return after f(1)?

  • A[1, 2] — the default list is created once, at def time
  • B[2] — a fresh default list is built for every single call
  • C[1, 2] — but only while the calls share one thread
  • DA TypeError — a mutable default is rejected at def time
Permalink & share
Sample · Python Fundamentals

What does 0.1 + 0.2 == 0.3 evaluate to?

  • AFalse — the sum is 0.30000000000000004, not 0.3
  • BTrue — Python rounds float results before comparing
  • CFalse — Python compares floats by identity, not value
  • DTrue — decimal literals are stored exactly as written
Permalink & share
How Gnoseed works

Learn it once, keep it for good

1

Answer a question

Each card is one practical concept with multiple options. Pick what you think is right.

2

Get the full answer

See the correct option plus a clear explanation, and a link to deeper docs when one is available.

3

Review at the right time

A spaced-repetition engine (SM-2 or FSRS) resurfaces each card just before you would forget it.

Why learn this

Why Python is worth your time

The default language of AI

Machine learning, data pipelines and LLM tooling all speak Python. Fluency here compounds across the entire AI ecosystem.

Readable, fast to write

Python’s clean syntax means less boilerplate and faster iteration — ideal for scripts, automation and prototypes alike.

Fewer bugs from gotchas

Mutable defaults, is vs ==, float equality — knowing the classic traps is how you stop chasing surprising bugs.

Interview-ready

Comprehensions, closures, decorators and the GIL are perennial favorites in Python interviews at every level.

FAQ

Common questions

Do I need prior programming experience? +

No. The track starts from core types and basic syntax, so motivated beginners can follow along — while experienced developers can use it to firm up the details they half-remember.

Does it cover the tricky parts like mutable default arguments? +

Yes. A dedicated Idioms & Gotchas module covers mutable defaults, is vs ==, truthiness, float comparisons, the GIL and more — exactly the fundamentals that trip people up.

Is it free? +

Yes, completely free. No registration or credit card is required, and all your progress is stored locally in your browser.

How long does it take? +

About 10 minutes a day. Spaced repetition means short, frequent sessions beat long cramming, so the syntax and idioms stick.

Ready to master Python?

Plant your first seed today. Ten minutes a day is all it takes to grow real, lasting Python fluency.

Start learning free