Class - 12 CBSE Computer Science — Assertion Reason Type Questions
Assertion(A): List is an immutable data type.
Reasoning(R): When an attempt is made to update the value of an immutable variable, the old variable is destroyed and a new variable is created by the same name in memory.
- Both A and R are true, and R is the correct explanation of A.
- Both A and R are true, and R is not the correct explanation of A.
- A is true but R is false.
- A is false but R is true.
Python List Manipulation
1 Like
Answer
Assertion is false but Reason is true.
Reason — List is a mutable data type. When an attempt is made to update the value of an immutable variable, the old variable is destroyed and a new variable with the updated value is created, and the variable name is reassigned to point to this new object in memory.
Answered By
2 Likes