I currently have this how can I get it so it checks for a float and uses a while loop
def get_float():
    number = input('Input a decimal number ')
    while number != float:
        print('bad input ')
        number = input('Input a decimal number ')
    else:
        return number
        
get_float()
        
right now even if I enter a decimal number it says bad input and asks for another input
 
     
    