Python Quiz Day-4

Python Quiz Day-4

University

15 Qs

quiz-placeholder

Similar activities

Memory-Mobo-Hard/Software

Memory-Mobo-Hard/Software

University

18 Qs

Linux: Users and Groups

Linux: Users and Groups

9th Grade - University

14 Qs

Revision Gr2-2025

Revision Gr2-2025

3rd Grade - University

12 Qs

PDSB 210622

PDSB 210622

University - Professional Development

10 Qs

Adobe Photoshop

Adobe Photoshop

University

10 Qs

HEAP TREE

HEAP TREE

University

11 Qs

Introduction to Mobile Commerce

Introduction to Mobile Commerce

University

10 Qs

After Effect Intoduction

After Effect Intoduction

10th Grade - University

15 Qs

Python Quiz Day-4

Python Quiz Day-4

Assessment

Quiz

Computers

University

Hard

Created by

SANJANA TUMPATI

FREE Resource

AI

Enhance your content in a minute

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

15 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the output of the following code?

python

print("Hello, World!"[7])

H

W

o

,

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which method can be used to convert a string to lowercase?

lowercase()

toLower()

lower()

downcase()

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What does the `split()` method do?

Splits the string into a list where each word is a list item

Splits the string into a list where each character is a list item

Splits the string into a list based on a delimiter

Both a and c

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the result of the following code?

"hello".capitalize()

Hello

HELLO

hello

HeLLo

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is not a valid string method in Python?

find()

replace()

append()

strip()

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What will be the output of the following code?

s = "Python Programming"

print(s[2:8])

thon P

ython P

thon Pr

ython Pr

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is the correct syntax to define a function in Python?

function myFunction():

def myFunction:

def myFunction():

function myFunction()

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

By signing up, you agree to our Terms of Service & Privacy Policy

Already have an account?