Geetting error in FUNCTION 19


#1


def distance_from_zero(s):
if type(s)==int :
return abs(s)
else:
return "Nope"

i am getting error while running this code in FUNCTIONS 19


Replace this line with your code.


#2

You should check if type(s) is float, too.


#3

thanks man.. i got it


#4

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.