Review Build in Functions:


This code looks right to me, what am I missing?

def distance_from_zero(name):
    if type(name) == int or type(name) == float:
        return abs(name)
        return 'nope'



Otherwise, the function should return "Nope"

string should be an exact match.

so it should be Nope


Thank you! That would have drove me nuts for a very long time!


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