
Files

Quiz
•
Computers
•
University
•
Medium
Vishnuvardhan Reddy Avija
Used 1+ times
FREE Resource
10 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following statements are true?
When you open a file for reading, if the file does not exist, an error occurs
When you open a file for writing, if the file does not exist, a new file is created
When you open a file for writing, if the file exists, the existing file is overwritten with the new file
All of the mentioned
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
To read two characters from a file object infile, we use
infile.read(2)
infile.read()
infile.readline()
infile.readlines()
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
To read the next line of the file from a file object infile, we use ____________
infile.read(2)
infile.read()
infile.readline()
infile.readlines()
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
The readlines() method returns ____________
str
a list of lines
a list of single characters
a list of integers
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following mode will refer to binary data?
r
w
b
+
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
In file handling, what does this terms means “r, a”?
read, append
append, read
write, append
none
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the use of “w” in file handling?
Read
Write
Append
None
Create a free account and access millions of resources
Similar Resources on Wayground
10 questions
2-列表与元组

Quiz
•
University
10 questions
LINUX 4TH MODULE QUIZ

Quiz
•
University
10 questions
PBO-09

Quiz
•
University
12 questions
Online World revision quiz 2

Quiz
•
University
10 questions
Chapter 11.1 Windows Desktop and File Explorer

Quiz
•
KG - Professional Dev...
10 questions
Python Tutorial

Quiz
•
University
15 questions
Python Workshop Day - 2

Quiz
•
University
8 questions
P7 File e Eccezioni

Quiz
•
University
Popular Resources on Wayground
10 questions
Lab Safety Procedures and Guidelines

Interactive video
•
6th - 10th Grade
10 questions
Nouns, nouns, nouns

Quiz
•
3rd Grade
10 questions
9/11 Experience and Reflections

Interactive video
•
10th - 12th Grade
25 questions
Multiplication Facts

Quiz
•
5th Grade
11 questions
All about me

Quiz
•
Professional Development
22 questions
Adding Integers

Quiz
•
6th Grade
15 questions
Subtracting Integers

Quiz
•
7th Grade
9 questions
Tips & Tricks

Lesson
•
6th - 8th Grade
Discover more resources for Computers
21 questions
Spanish-Speaking Countries

Quiz
•
6th Grade - University
20 questions
Levels of Measurements

Quiz
•
11th Grade - University
7 questions
Common and Proper Nouns

Interactive video
•
4th Grade - University
12 questions
Los numeros en español.

Lesson
•
6th Grade - University
7 questions
PC: Unit 1 Quiz Review

Quiz
•
11th Grade - University
7 questions
Supporting the Main Idea –Informational

Interactive video
•
4th Grade - University
12 questions
Hurricane or Tornado

Quiz
•
3rd Grade - University
7 questions
Enzymes (Updated)

Interactive video
•
11th Grade - University