MODULE 3_Python

MODULE 3_Python

Professional Development

13 Qs

quiz-placeholder

Similar activities

Python Rocks

Python Rocks

University - Professional Development

10 Qs

Topic Quiz-1 : Python Basics

Topic Quiz-1 : Python Basics

Professional Development

10 Qs

DBMS Quiz2

DBMS Quiz2

University - Professional Development

10 Qs

PYTHON INTRODUCTION

PYTHON INTRODUCTION

Professional Development

15 Qs

coding

coding

KG - Professional Development

15 Qs

Python

Python

8th Grade - Professional Development

10 Qs

Function and Conditional in Python

Function and Conditional in Python

Professional Development

10 Qs

Introdução a Liguagem de Programação Python

Introdução a Liguagem de Programação Python

Professional Development

13 Qs

MODULE 3_Python

MODULE 3_Python

Assessment

Quiz

Computers

Professional Development

Hard

Created by

Sumathi K

FREE Resource

13 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following methods is used to add a new key-value pair to a Python dictionary?

add()

insert()

append()

None of the above

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

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

[‘a’, ‘b’, ‘c’]

(‘a’, ‘b’, ‘c’)

dict_keys([‘a’, ‘b’, ‘c’])

{‘a’, ‘b’, ‘c’}

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

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

(‘a’, 1), (‘b’, 2), (‘c’, 3)]

((‘a’, 1), (‘b’, 2), (‘c’, 3))

dict_items([(‘a’, 1), (‘b’, 2), (‘c’, 3)])

{(‘a’, 1), (‘b’, 2), (‘c’, 3)}

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following methods is used to add an element to the end of a list in Python?

append()

add()

insert()

extend()

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

What is the output of the following Python code snippet?

[3, 4]

2, 3, 4]

[1, 2, 3]

[4, 5]

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

What does the following Python code snippet do?

Prints “Hello, World!” in lowercase

Converts “Hello, World!” to uppercase and prints it

Reverses the string “Hello, World!”

Removes all whitespace characters from the string “Hello, World!

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What does the isupper() method return if all characters in a string are uppercase?

True

False

1

Error

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?