Quiz on Python Serialization
FREE Online Courses: Knowledge Awaits – Click for Free Access!
Quiz Summary
0 of 15 Questions completed
Questions:
Information
You have already completed the quiz before. Hence you can not start it again.
Quiz is loading…
You must sign in or sign up to start the quiz.
You must first complete the following:
Results
Results
0 of 15 Questions answered correctly
Your time:
Time has elapsed
You have reached 0 of 0 point(s), (0)
Earned Point(s): 0 of 0, (0)
0 Essay(s) Pending (Possible Point(s): 0)
Categories
- Not categorized 0%
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
- 11
- 12
- 13
- 14
- 15
- Current
- Review / Skip
- Answered
- Correct
- Incorrect
-
Question 1 of 15
1. Question
- Which of the following is not correct about the Serialization?
CorrectIncorrect -
Question 2 of 15
2. Question
- Which of the following is not an argument of the dumps function?
CorrectIncorrect -
Question 3 of 15
3. Question
- Which of the following are not the constants in the Pickle module?
CorrectIncorrect -
Question 4 of 15
4. Question
- Which of the following is a function of the Pickler object?
CorrectIncorrect -
Question 5 of 15
5. Question
- Which of the following is the difference between Pickler and JSON?
CorrectIncorrect -
Question 6 of 15
6. Question
- Which of the following is the correct way to serialize the data into a file?
CorrectIncorrect -
Question 7 of 15
7. Question
- What is the output of the below code?
-
import pickle
content = ‘Python’
pickled_content = pickle.dumps(content)
print(type(pickled_content))
CorrectIncorrect -
Question 8 of 15
8. Question
- What is the output of the below code?
import pickle
content = ‘PythonGeeks’
pickled_content = pickle.dumps(content)
reconstructed_content = pickle.loads(pickled_content)
print(content==reconstructed_content,end=’ ‘)
print(content is reconstructed_content)
CorrectIncorrect -
Question 9 of 15
9. Question
- Find the code that can be used for deserializing byte stream from a file?
CorrectIncorrect -
Question 10 of 15
10. Question
- What does the below code do?
-
import pickle
x=10
pickle.dumps(x)
CorrectIncorrect -
Question 11 of 15
11. Question
- What is the output of the below code?
pickle.HIGHEST_PROTOCOL
CorrectIncorrect -
Question 12 of 15
12. Question
- Which of the following gives an error if content=10?
CorrectIncorrect -
Question 13 of 15
13. Question
- Find the output of the below code?
import json
info = {
“a”: “5”,
“b”: “9”,
“c”: “3”
}
serialized_info = json.dumps(info)
#Deserializing using json
deserialized_info = json.loads(serialized_info)
print(type(serialized_info))
CorrectIncorrect -
Question 14 of 15
14. Question
- What is the output of the below code?
-
import json
def func():
print(‘Hello’,end=’ ‘)
serialized_info = json.dumps(func())
#Deserializing using json
deserialized_info = json.loads(serialized_info)
print(deserialized_info)
CorrectIncorrect -
Question 15 of 15
15. Question
- Which of the following is used to serialize using Marshal?
CorrectIncorrect