NRIT_Python_Quiz02

NRIT_Python_Quiz02

University

50 Qs

quiz-placeholder

Similar activities

Midterm prep 10 gr

Midterm prep 10 gr

10th Grade - University

45 Qs

Ôn tập

Ôn tập

10th Grade - University

46 Qs

Python Basic

Python Basic

University

50 Qs

C++ ECE Q1

C++ ECE Q1

University

55 Qs

2nd C Programming Quiz

2nd C Programming Quiz

University

50 Qs

Pre-Test Praktikum

Pre-Test Praktikum

University

50 Qs

Python Quiz

Python Quiz

University

45 Qs

Python PCAP 31-03

Python PCAP 31-03

University

50 Qs

NRIT_Python_Quiz02

NRIT_Python_Quiz02

Assessment

Quiz

Computers

University

Medium

Created by

Yohoshiva Basaraboyina

Used 1+ times

FREE Resource

50 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the output of print([1, 2, 3] + [4, 5, 6])?

[1, 2, 3, 4, 5, 6]

[5, 7, 9]

[4, 5, 6, 1, 2, 3]

Error

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What does list1.append(5) do?

Adds 5 to the end of list1

Inserts 5 at index 0

Deletes index 5

Raises an error

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the output of print(len([1, [2, 3], 4]))?

3

4

5

2

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How do you remove an element from a list by value?

list.remove(value)

list.delete(value)

list.pop(value)

del list[value]

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the result of list1 = [1, 2, 3] and list1 * 2?

[1, 2, 3, 1, 2, 3]

[1, 2, 3, 2]

[1, 2, 3, 1]

[2, 4, 6]

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the output of dict1 = {'a':1, 'b':2}; print(dict1['a'])?

'a'

1

2

Error

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How can you get all the keys of a dictionary?

dict.keys()

dict.values()

dict.items()

dict.get()

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?