1.

What is returned by math.modf(1.0)?(a) (0.0, 1.0)(b) (1.0, 0.0)(c) (0.5, 1)(d) (0.5, 1.0)I got this question by my school teacher while I was bunking the class.This intriguing question originated from Math topic in division Mapping Functions and Modules of Python

Answer»

Right ANSWER is (a) (0.0, 1.0)

To explain: The FIRST element is the FRACTIONAL part and the SECOND element is the integral part of the ARGUMENT.



Discussion

No Comment Found

Related InterviewSolutions