Q1
1 markVery Short AnswerSection A

State True or False :

In Python, data type of 74 is same as the data type of 74.0.

Review of Python Basics (Class XI Recap)
Data Types in Python
Official Answer

False. 74 is an integer (int) while 74.0 is a floating-point number (float) — they are different data types in Python even though they represent the same numeric value.

data typeintfloattype() functionnumeric literalvalue vs typePython fundamentals

Marking Scheme

  • 11 mark: for correctly stating 'False' (accept with or without justification, as full marks are for the correct answer).

Hint

Check with type() — same value can still belong to different data types.

Quick Oral Answer

False — 74 is of type int and 74.0 is of type float; use type() to verify: type(74) gives int, type(74.0) gives float.

Analysis & Explanation

Python distinguishes between numbers based on how they are written, not just their numeric value.


Concept

  • A number written without a decimal point, like 74, is stored as an int.
  • A number written with a decimal point, like 74.0, is stored as a float, even though 74 == 74.0 evaluates to True in terms of value.
  • type(74) returns <class 'int'> while type(74.0) returns <class 'float'>.

Why the statement is False

  • Value-equality (==) and type-identity (type()) are different checks in Python.
  • The two literals are numerically equal but structurally stored differently (int vs. float representation).

Exam trap

  • Students often confuse 'equal value' with 'same data type' — CBSE frequently tests this exact distinction.

Real-world relevance

  • This distinction matters in database schemas and file I/O, where storing a value as int vs. float affects storage size and precision (e.g., financial calculations).

Common Mistakes

  1. 1Assuming that because 74 == 74.0 is True, both must have the same data type.
  2. 2Confusing value equality with type equality.

Interesting Facts

Python's int type has unlimited precision (limited only by memory), unlike C/C++ int which is fixed-width.

In Python, True and False are actually subtypes of int (bool is a subclass of int), so True == 1 is also True — but type(True) is not the same as type(1).

Spotted a mistake or something unclear?

Tell us — we fix reported answers fast.

Frequently Asked Questions

Does 74 == 74.0 return True in Python?

Yes, `74 == 74.0` returns True because Python compares values, not types, with the == operator. However, `type(74) == type(74.0)` returns False since one is int and the other is float.

How can I check the data type of a value in Python?

Use the built-in `type()` function, e.g., `type(74)` returns `<class 'int'>` and `type(74.0)` returns `<class 'float'>`.