Python-Week7

Python-Week7

University

25 Qs

quiz-placeholder

Similar activities

User Support Quiz

User Support Quiz

University

20 Qs

Python QCM

Python QCM

University

21 Qs

Type Conversions and Computation

Type Conversions and Computation

University

20 Qs

пүтон 80-100

пүтон 80-100

University

21 Qs

HTML_CSS_JAVASCRIPT

HTML_CSS_JAVASCRIPT

University - Professional Development

20 Qs

Python workshop day2

Python workshop day2

University

20 Qs

Introduction to Python and Data Analytics Basics

Introduction to Python and Data Analytics Basics

University

25 Qs

Season 4 #Spaic Python Weekly Quiz

Season 4 #Spaic Python Weekly Quiz

KG - Professional Development

20 Qs

Python-Week7

Python-Week7

Assessment

Quiz

Other

University

Easy

Created by

Yahini Prabha Murugesan

Used 2+ times

FREE Resource

25 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

If a file with the specified name already exists when the file is opened and the file is opened in 'w' mode, then an alert will appear on the screen.

True

False

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

The ZeroDivisionError exception is raised when the program attempts to perform the calculation x/y if y = 0.

True

False

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following describes what happens when a piece of data is written to a file?

The data is copied from a variable in RAM to a file.

The data is copied from the program to a file.

The data is copied from a file object to a file.

The data is copied from a variable in the program to a file.

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which type of file access jumps directly to a piece of data in the file without having to read all the data that comes before it?

numbered

sequential

text

random

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which mode specifier will open a file but not let you change the file or write to it?

r

w

a

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which method could be used to strip specific characters from the end of a string?

strip

lstrip

rstrip

remove

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which statement can be used to handle some of the runtime errors in a program?

an exception handler statement

a try statement

a try/except statement

an exception statement

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?