NRIT_Python_Quiz-01

NRIT_Python_Quiz-01

University

30 Qs

quiz-placeholder

Similar activities

Understanding Loops in Programming

Understanding Loops in Programming

University

25 Qs

ITE6 Prelim exam BSIT 2-3

ITE6 Prelim exam BSIT 2-3

University

25 Qs

INFORMATICA BASICA FINAL _SENATINOS

INFORMATICA BASICA FINAL _SENATINOS

University

25 Qs

UTS manajemen data 2017, FKM Universitas Malahayati

UTS manajemen data 2017, FKM Universitas Malahayati

University

25 Qs

De grote herhalingsquiz

De grote herhalingsquiz

University

25 Qs

Arduino

Arduino

University

25 Qs

PAT ROBOTIC Elektronika Dasar 2019-2020

PAT ROBOTIC Elektronika Dasar 2019-2020

KG - Professional Development

25 Qs

Speed Cup de Ingeniería 2021 (Eliminatoria)

Speed Cup de Ingeniería 2021 (Eliminatoria)

1st Grade - University

25 Qs

NRIT_Python_Quiz-01

NRIT_Python_Quiz-01

Assessment

Quiz

Computers

University

Practice Problem

Medium

Created by

Yohoshiva Basaraboyina

Used 5+ times

FREE Resource

AI

Enhance your content in a minute

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

30 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the correct way to create an empty list in Python?

list = ()

list = []

list = {}

list = None

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following methods can be used to add an element to a list in Python?

list.insert(index, element)

list.append(element)

list.add(element)

All of the above

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What will be the output of the following code: print(type([]))?

<class 'list'>

<class 'tuple'>

<class 'dict'>

<class 'set'>

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How can you remove the last item from a list in Python?

list.remove()

list.pop()

del list[-1]

All of the above

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How do you access the second element of a list my_list = [10, 20, 30, 40]?

my_list(1)

my_list[1]

my_list{1}

my_list[2]

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

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

3

4

5

Error

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How do you remove the last element of a list?

list.remove(-1)

list.pop()

del list[-1]

Both (b) and (c)

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