Python Quizz-11

Python Quizz-11

University

10 Qs

quiz-placeholder

Similar activities

Ke-Al Azhar 8 an

Ke-Al Azhar 8 an

7th Grade - University

10 Qs

DBMS-Quiz1

DBMS-Quiz1

University

15 Qs

Manajemen Proyek TI

Manajemen Proyek TI

University

10 Qs

Hệ Điều Hành Của Máy Tính

Hệ Điều Hành Của Máy Tính

10th Grade - University

10 Qs

AI - 2023

AI - 2023

University

15 Qs

Centros de datos perimetral

Centros de datos perimetral

University

12 Qs

Computer Science Quiz

Computer Science Quiz

University

15 Qs

Tutorium1

Tutorium1

University

10 Qs

Python Quizz-11

Python Quizz-11

Assessment

Quiz

Computers

University

Practice Problem

Medium

Created by

shilpa gupta

Used 24+ times

FREE Resource

AI

Enhance your content in a minute

Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...

10 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following statements create a dictionary?

d = {}

d = {“john”:40, “peter”:45}

d = {40:”john”, 45:”peter”}

All of the mentioned

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What will be the output of the following Python code snippet?

d = {"john":40, "peter":45}

print("john" in d)

True

False

None

Error

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

d1 = {"john":40, "peter":45}

d2 = {"john":466, "peter":45}

print(d1 == d2)

True

False

None

Error

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

d1 = {"john":40, "peter":45}

d2 = {"john":466, "peter":45}

print(d1 > d2)

True

False

Error

None

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

d = {"john":40, "peter":45}

print(d["john"])

45

40

john

error

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Suppose d = {“john”:40, “peter”:45}. To obtain the number of entries in dictionary which command do we use?

d.size()

len(d)

size(d)

d.len()

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

d = {"john":40, "peter":45}

print(list(d.keys()))

[“john”, “peter”]

[“john”:40, “peter”:45]

(“john”, “peter”)

(“john”:40, “peter”:45)

Create a free account and access millions of resources

Create resources

Host any resource

Get auto-graded reports

Google

Continue with Google

Email

Continue with Email

Classlink

Continue with Classlink

Clever

Continue with Clever

or continue with

Microsoft

Microsoft

Apple

Apple

Others

Others

Already have an account?