file
has been opened in read mode, which of the following will read one line of data at a timefile.read()
and file.readlines()
?with open("hello.txt") as my_file:
guarantees which of the following after the block of code following the :
is executed?Which if the following is a tuple?
Which if the following is a list?
Which if the following is a set?
Which if the following is a dictionary?
What is the use case for a tuple?
What is the use case for a dictionary?
What is the use case for a list?
What is the use case for a set?
Python strings are mutable.
Lists and Tuples are ordered collections.
If `data_list = ['a', 'b', 'c'] which of the following will unpack the list?
If you want to split
a string from a CSV file in order to create a list
, why
is it important to strip
the string before splitting it?