Search⌘ K
AI Features

Quiz: Dictionaries

Test your understanding of Python dictionaries by completing a quiz that reinforces how to create and manage key–value pairs. Learn to organize and access data effectively using dictionaries, an essential structure for building smarter programs. This lesson prepares you to use dictionaries in practical projects that capture personal details and other key information.

We'll cover the following...

In the last lesson, you learned how to use dictionaries—Python’s tool for storing data using labeled keys. Unlike lists, which store items in order, dictionaries store key–value pairs, letting you label and organize your data in a way that’s easy to access, update, and loop through.

Now, test your understanding with a quick quiz!

Technical Quiz
1.

What is the correct syntax to create a dictionary in Python?

A.

dict = {"name": "Alice", "age": 25}

B.

dict = []

C.

dict = {key - value}


1 / 3

Nice work! You’ve learned how to create and manage dictionaries—one of Python’s most powerful tools for organizing labeled information.

What’s next?

Now it’s time to let Python remember a few things about you! In this hands-on project, you’ll:

  • Create a dictionary called me.

  • Add keys like "name", "hobby", "language", and any other fun facts.

  • Use a for loop to print each key and its value in a clean, readable format.

Dictionaries are great for building profiles, organizing data, and making your programs smarter. Let’s teach Python what makes you unique!