Search Header Logo

Python Data structures

Authored by Dimitra Mavroforaki

Computers

University

Used 4+ times

Python Data structures
AI

AI Actions

Add similar questions

Adjust reading levels

Convert to real-world scenario

Translate activity

More...

    Content View

    Student View

20 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is NOT valid variable name in python?

Myvar123

my_var

1_myvar

_myvar1

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What the answer of the expression 22 % 3 is?

1

7

0

5

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of these commands will create a list?

list1=[1,2,3]

list1=list("123")

list1=[]

All of these

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which method should I use to convert String "welcome to the beautiful world of python" to "Welcome To The Beautiful World Of Python"

capitalize()

upper()

None of the above

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

Following set of commands are executed in shell, what will be the output?

hello

lo

he

hel

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

The following is displayed by a print function call:

tom

nick

harry

Select all of the function calls that result in this output

print("tomnickharry")

print("tom

nick

harry")

print("tom\nnick\nharry")

print("tom/nnick/nharry")

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

What is the output when following code is executed?

Daman

n

D

Error

Access all questions and much more by creating a free account

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?

Discover more resources for Computers