Practice Summary Of Dictionaries (23.1.14) - Tuples and dictionaries - Data Structures and Algorithms in Python
Students

Academic Programs

AI-powered learning for grades 8-12, aligned with major curricula

Professional

Professional Courses

Industry-relevant training in Business, Technology, and Design

Games

Interactive Games

Fun games to boost memory, math, typing, and English skills

Summary of Dictionaries

Practice - Summary of Dictionaries

Learning

Practice Questions

Test your understanding with targeted questions

Question 1 Easy

Create a dictionary to store three fruits and their prices.

💡 Hint: Use fruit names as keys and their prices as values.

Question 2 Easy

Access the price of 'banana' from the dictionary you created.

💡 Hint: The key is 'banana'.

4 more questions available

Interactive Quizzes

Quick quizzes to reinforce your learning

Question 1

What is the data type used for keys in a Python dictionary?

Mutable types
Immutable types
Any types

💡 Hint: Think about what dictionaries use to access values.

Question 2

True or False: You can have duplicate keys in a dictionary.

True
False

💡 Hint: Consider the purpose of keys.

2 more questions available

Challenge Problems

Push your limits with advanced challenges

Challenge 1 Hard

Create a nested dictionary for three sports teams, with each team having players and their respective scores. Write a function to calculate the total score for each team.

💡 Hint: Loop through team names and sum their player scores.

Challenge 2 Hard

Given a dictionary representing book titles and authors, write a function that returns a list of authors whose names start with a vowel.

💡 Hint: Filter authors by checking the first letter.

Get performance evaluation

Reference links

Supplementary resources to enhance your learning experience.