Python Basics
Quiz
•
Computers
•
Professional Development
•
Practice Problem
•
Medium
Urvashi Thapar
Used 6+ times
FREE Resource
Enhance your content in a minute
10 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following code snippets is the correct one for opening the hello.txt file for writing?
output_file = open("hello.txt", "r")
output_file = openFile("hello.txt", "w")
output_file = open("hello.txt", "w")
output_file = File("hello.txt", "w")
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
which mode is used to open a file for exclusive creation?
r
w
x
a
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
When you open a file using a with statement, Python will ________ the file automatically after you access it.
close
reset
delete
archive
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which operator can be used on a pathlib.Path object to extend the path it represents with subdirectories or filenames?
\
/
|
*
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What does strip() do?
removes the content of the file
add in meta data
splits the file
Removes extra data at the beginning / end of the string
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
var = = {"apple", "banana", "cherry"}, represents:
sets
dictionary
tuple
list
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
df.shape is used to index, Datatype and Memory information
True
False
Create a free account and access millions of resources
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?
Similar Resources on Wayground
12 questions
eContent Development Tools
Quiz
•
Professional Development
14 questions
Tin học 7 - ÔT Cuối kì 2 CĐ Bảng tính - Trình chiếu
Quiz
•
Professional Development
12 questions
BIS - Database
Quiz
•
Professional Development
15 questions
Kelas X 28 Spreadsheet 2020
Quiz
•
Professional Development
13 questions
Javascript HTML CSS
Quiz
•
Professional Development
10 questions
Kiểm tra miệng: Bài 18 - Tin học 10
Quiz
•
Professional Development
13 questions
google drive
Quiz
•
Professional Development
15 questions
Javascript basics
Quiz
•
Professional Development
Popular Resources on Wayground
10 questions
Honoring the Significance of Veterans Day
Interactive video
•
6th - 10th Grade
9 questions
FOREST Community of Caring
Lesson
•
1st - 5th Grade
10 questions
Exploring Veterans Day: Facts and Celebrations for Kids
Interactive video
•
6th - 10th Grade
19 questions
Veterans Day
Quiz
•
5th Grade
14 questions
General Technology Use Quiz
Quiz
•
8th Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
15 questions
Circuits, Light Energy, and Forces
Quiz
•
5th Grade
19 questions
Thanksgiving Trivia
Quiz
•
6th Grade
