Skip to content
Logo Logopumping python: how I solve problems with Test Driven Development
⌘ K
Logo Logopumping python: how I solve problems with Test Driven Development
  • pumping python: how I solve problems with test driven development
  • videos
  • conventions
  • setup
    • setup my computer
    • install WSL on Windows
  • make TDD environment 1
    • make a Python TDD environment
    • make a Python TDD environment no WSL
  • AssertionError
  • what is a function?
  • pass values
  • what is None?
  • what are booleans?
  • truth table
    • Nullary and Unary
    • Binary Operations 1
    • Binary Operations 2
    • Binary Operations 3
    • Binary Operatiosn 4
    • Truth Table Test
  • calculator
  • make TDD environment 2
    • make TDD automatically
    • make TDD automatically no WSL
  • handling Exceptions
    • handle Exceptions in tests
    • handle Exceptions in programs
    • how to make a calculator part 2
  • what causes TypeError?
    • TypeError
    • how to make a calculator part 3
  • what is a list?
    • lists
    • how to make a calculator part 4
    • list comprehensions
    • how to make a calculator part 5
    • booleans part 2
  • what is a dictionary?
    • dictionaries
    • how to make a calculator part 6
  • make a person
  • what is a class?
  • AttributeError
  • ModuleNotFoundError
  • dot notation
  • errors
    • AssertionError
    • ModuleNotFoundError
    • AttributeError
    • what causes TypeError?
    • handling Exceptions
  • data structures
    • None: the simplest
    • Booleans: only 2
    • Lists: anything in [ ]
    • Dictionaries: key-value pairs
  • how tos
    • setup my computer
    • make TDD manually
    • make TDD automatically
    • how to pass values
    • calculator 1
    • how to make a person
    • handle Exceptions
  • catalog of tests
  • all the code in this book
    • makePythonTdd.sh
    • makePythonTdd.ps1
    • AssertionError
    • None
    • booleans
    • truth table
    • how to pass values
    • functions
    • how to make a calculator
    • how to test/handle exceptions
    • TypeError
    • lists
    • list comprehensions
    • dictionaries
    • how to make a person
    • classes
    • ModuleNotFoundError
    • AttributeError
    • how to measure sleep duration
  • questions the book answers
  • can we measure learning?
  • what people think of this
  • join a HATCH

Table of Contents

  • the chapters
  • code from the chapter
  • what is next?
  • rate pumping python
pumping python: how I solve problems with Test Driven Development
/
what is a dictionary?



what is a dictionary?

A dictionary also known as a Mapping is a way to keep key-value pairs, the values can be any Python object. I add tests to see which of the Python basic data types I can use as keys .

I think this is the most important data structure because it can hold all the other data structures, same as with lists and tuples but with more. In programming I have had to work with JSON which I can read and write as dictionaries


the chapters

  • dictionaries
  • how to make a calculator part 6

code from the chapter

Do you want to see all the CODE I typed in these chapter?


what is next?

you know

  • how to make a test driven development environment manually

  • how to raise AssertionError with assert methods

  • how to write functions

  • how to pass values from tests to functions

  • what None is

  • what is True and False in Python

  • how to write programs that make decisions

  • how to make a calculator

  • how to test that an Exception is raised with assertRaises

  • how to handle Exceptions in programs with try…except…else

  • how to raise TypeError

  • how to make the calculator check if its inputs are numbers

  • what you can do with Lists

Would you like to test list comprehensions? They are a quick way to make lists


rate pumping python

If this has been a 7 star experience for you, please leave a 5 star review. It helps other people get into the book too

CLICK HERE to leave a 5 star review, if this has been a 7 star experience for you
booleans part 2
dictionaries

On this page

  • the chapters
  • code from the chapter
  • what is next?
  • rate pumping python

© 2026, JadeCobra LLC Built with Sphinx 8.2.3