Need help here distance from zero


i need help here!!!
my code:
def distance_from_zero(number):
if type(number) == int or type(number) == float:
return abs(int)
return "nope"

19. Review: Built-In_Functions

Try this code by taking the problem in another way ... upside somehow, it work fine !
Caution : it's better not to copy/paste the code but write it in the editor

def distance_from_zero(param):
    typeParam = type(param)
    if not typeParam != int or not typeParam != float:
        return abs(param)
        return "Nope"
# Test

def distance_from_zero(d): #make an function called distance_from_zero and assign to variable (d)
    if type(d) == int or type(d) == float:  #fucntion if ask for variable (d) are equal to integer or float
        return abs(d) #if true it will go to function return(d) into abs
        return("Nope") #if not true will go to function return to show Nope

try this code,i think its simply to understand