Python Data Types Quiz

69

Python Data Types Quiz

This is a quiz regarding the Python Data Types.

Please go through the below topics

1. Python Data Types

1) What is the output of the following code:
print(round(-0.5))

2) What is the output of the following code:
print(round(-5.5))

3) Which of the following is a correct integer declaration?

4) What is the output of the following code?
print(0.01 + 0.99 == 1.0)

5) Which of the following is a mutable data type?

6) Which of the following is an immutable data type?

7) What is the output of the following code?
temp = {}
print(type(temp))

8) What is the output of the following code?
temp = {1}
print(type(temp))

9) The datatype similar to list but is not mutable?

10) Which sequence in Python cannot have duplicate values?

11) Python has three mutable data types. What are they?

12) What is the precision of floating-point numbers in Python?

13) Floating-point numbers are of two forms:

14) Boolean data type in internally treated as?

15) We declare the variable in Python before assigning it a value?

16) In the below statements:


a = 35
m = 0

How many objects and references gets created?

17) In Python, we reassign a variable with the value of a different type. This is known as:

Your score is

The average score is 59%

0%