Review: built in functions (python)


#1



https://www.codecademy.com/courses/python-beginner-c7VZg/4/3?curriculum_id=4f89dab3d788890003000096


returns "none" instead of "10"


instead i want it to return "10" i just dont know whats wrong on my code...


def distance_from_zero(n):
    if type(n) == int or type(n) == float:
        abs(n)
    else:
        return "Nope"


#2

you forgot the return keyword


#3

where exaclty? (also thanks for answering)


#4

here:

abs(n)

#5

many thanks i was stuck there quite a while... thanks a lot


#6