CBSE Class 12 Informatics Practices
Question 7 of 167
Python Pandas — I — Question 7
Back to all questions 7
Question Assertion. Arithmetic operations on two series objects take place on matching indexes.
Reason. For non-matching indexes of series objects in an arithmetic operation, NaN is returned.
- Both A and R are true and R is the correct explanation of A.
- Both A and R are true but R is not the correct explanation of A.
- A is true but R is false.
- A is false but R is true.
Both A and R are true and R is the correct explanation of A.
Explanation
Arithmetic operations on two Series objects take place on matching indexes. When performing operations on objects with non-matching indexes, Pandas aligns the indexes and adds values for matching indexes, resulting in NaN (Not a Number) for non-matching indexes in both objects.