Home/Learning Hub/Python
Workshop 1 of 3
Python
Learn to think like a programmer. Write real Python from your first line to a finished game.
- Level
- Beginner. No coding experience needed.
- Who it is for
- Students from about 4th grade up, and any adult new to programming.
- Length
- 5 sessions, about 5.3 hours in total
- You need
- A web browser
- An online Python editor such as Replit, Trinket or Google Colab (free), or Python 3 installed on your computer
- Before you start
- A computer with internet access. A free account on an online Python editor, or Python installed.
What you will be able to do
- Store and use information with variables
- Make programs decide with if and else
- Repeat work with loops
- Organize data with lists and dictionaries
- Build your own functions and a finished number guessing game
Final project: A number guessing game with a score and a play-again option.
The five sessions
- Session 1
Hello, Python
Write your first program, store information in variables, and ask the user a question.
- Session 2
Making Decisions
Compare values and make your program choose what to do with if, elif and else.
- Session 3
Loops
Make the computer repeat work for you with for loops, while loops and range().
- Session 4
Lists and Dictionaries
Keep many values together in a list, and look things up by name in a dictionary.
- Session 5
Functions and the Guessing Game
Package code into reusable functions, then combine everything you have learned into a finished game.
Next workshop: Machine Learning