
Dictionary in Python

Quiz
•
Computers
•
11th Grade
•
Hard
Sangeetha John
Used 11+ times
FREE Resource
10 questions
Show all answers
1.
FILL IN THE BLANK QUESTION
1 min • 1 pt
What will be the output of following code-
a={1:"A",2:"B",3:"C"}
for i in a:
print(i,end=" ")
2.
FILL IN THE BLANK QUESTION
2 mins • 1 pt
What will be the output of following code-
a={i: i*i for i in range(6)}
a
3.
FILL IN THE BLANK QUESTION
1 min • 1 pt
a={}
a[2]=1
a[1]=[2,3,4]
print(a[1][1])
4.
FILL IN THE BLANK QUESTION
1 min • 1 pt
What will be the output of following program:
dictionary = {1:'1', 2:'2', 3:'3'}
del dictionary[1]
dictionary[1] = '10'
del dictionary[2]
print(len(dictionary))
5.
FILL IN THE BLANK QUESTION
2 mins • 1 pt
What will be the output of following program:
a={1:5,2:3,3:4}
a.pop(3)
print(a)
6.
FILL IN THE BLANK QUESTION
1 min • 1 pt
What will be the output of following program:
my_dict = {}
my_dict[(1,2,4)] = 8
my_dict[(4,2,1)] = 10
my_dict[(1,2)] = 12
sum = 0
for k in my_dict:
sum += my_dict[k]
print (sum)
7.
FILL IN THE BLANK QUESTION
1 min • 1 pt
What will be the output of following program:
a = {(1,2):1,(2,3):2}
print(a[1,2])
Create a free account and access millions of resources
Similar Resources on Wayground
15 questions
Python Basics

Quiz
•
KG - University
10 questions
Quiz1_HPB2021_2010t1

Quiz
•
1st - 12th Grade
15 questions
Python Programming Random Quiz

Quiz
•
11th Grade
9 questions
Intermediate python

Quiz
•
9th - 12th Grade
10 questions
Python Generators

Quiz
•
10th Grade - University
9 questions
Python Code Snippet Quiz

Quiz
•
11th Grade
7 questions
Python-list,tuple,Dictionary

Quiz
•
11th - 12th Grade
15 questions
Python Lists

Quiz
•
10th - 12th Grade
Popular Resources on Wayground
10 questions
SR&R 2025-2026 Practice Quiz

Quiz
•
6th - 8th Grade
30 questions
Review of Grade Level Rules WJH

Quiz
•
6th - 8th Grade
6 questions
PRIDE in the Hallways and Bathrooms

Lesson
•
12th Grade
10 questions
Lab Safety Procedures and Guidelines

Interactive video
•
6th - 10th Grade
10 questions
Nouns, nouns, nouns

Quiz
•
3rd Grade
25 questions
Multiplication Facts

Quiz
•
5th Grade
11 questions
All about me

Quiz
•
Professional Development
15 questions
Subtracting Integers

Quiz
•
7th Grade
Discover more resources for Computers
20 questions
Lab Safety and Lab Equipment

Quiz
•
9th - 12th Grade
7 questions
EAHS PBIS Lesson- Bathroom

Lesson
•
9th - 12th Grade
57 questions
How well do YOU know Neuwirth?

Quiz
•
9th - 12th Grade
20 questions
Getting to know YOU icebreaker activity!

Quiz
•
6th - 12th Grade
6 questions
Secondary Safety Quiz

Lesson
•
9th - 12th Grade
4 questions
Study Skills

Lesson
•
5th - 12th Grade
15 questions
Let's Take a Poll...

Quiz
•
9th Grade - University
20 questions
Points, Lines & Planes

Quiz
•
9th - 11th Grade