warming up your workspace

Python Foundations through Climate Modeling

Never written code before? Start here. You will learn the absolute basics of Python, output, variables, types, decisions, loops, and functions, using temperature readings, CO2 levels, energy balance, and sea level as your playground. By the end you are ready for Project 1.

First words

  1. Display your first station message
  2. Display whole numbers and decimal values
  3. Explain a supplied value with a comment
  4. Display a station name and location
  5. Calculate a net energy flux

Remembering things

  1. Store a CO2 value under a name
  2. Update a stored CO2 value
  3. Store numbers, text and a boolean flag
  4. Convert a text temperature to an integer
  5. Name climate quantities clearly

Making choices

  1. Compare a supplied temperature anomaly with a threshold
  2. Display a message when a flag is true
  3. Choose a message with if and else
  4. Classify a CO2 value with elif
  5. Combine report flags with and

Doing it again

  1. Repeat a decade countdown with while
  2. Generate year labels with for and range
  3. Build a running total of observations
  4. Read a budget loop that stops with break
  5. Visit grid positions with nested loops

Many values and reuse

  1. Store CO2 readings in a list
  2. Find the largest supplied temperature anomaly
  3. Define a function for a CO2 forcing approximation
  4. Return an absorbed fraction from an albedo
  5. Build a CO2 summary report

Explore the full field