Welcome to this “Challenge Course”. Until now we’ve been leading you by the hand and working on some short and relatively easy projects. This is a challenge so be ready. We have faith in you!
We’re going to switch it up a bit and allow you to be the teacher of your own class. Make a gradebook for all of your students.
animal = { "name": "Mr. Fluffles", "sounds": ["meow", "purr"] } print animal["name"]
The example above is just to remind you how to create a dictionary and then to access the item stored by the "name"
key.
Instructions
Create three dictionaries: lloyd
, alice
, and tyler
.
Give each dictionary the keys "name"
, "homework"
, "quizzes"
, and "tests"
.
Have the “name” key be the name of the student (that is, lloyd
‘s name should be "Lloyd"
) and the other keys should be an empty list (We’ll fill in these lists soon!)