CBSE Class 12 Informatics Practices Question 50 of 101

Python Pandas — II — Question 5

Back to all questions
5
Question

Question 5

The result produced by the functions div() and rdiv() is the same.

Answer

False

Reason — The div() and rdiv() functions do not produce the same result. The div() function performs element-wise division between two DataFrames, where the left operand is the dividend and the right operand is the divisor. The syntax is <DF1>.div(<DF2>), which means <DF1> / <DF2>. On the other hand, the rdiv() function performs element-wise division with the right operand as the dividend and the left operand as the divisor. The syntax is <DF1>.rdiv(<DF2>), which means <DF2> / <DF1>.