1.

Is the output of the function abs() the same as that of the function math.fabs()?(a) sometimes(b) always(c) never(d) none of the mentioned

Answer» Right option is (a) sometimes

Easy explanation - math.fabs() always returns a float and does not work with complex numbers whereas the return type of abs() is determined by the type of value that is passed to it.


Discussion

No Comment Found