6. Practice Makes Perfect Bug



I think my code is right but it doesn't work. It keeps on saying this error message:
Oops, try again. by_three(3) returned True instead of 27

def cube(number):
    return number ** 3

def by_three(number):
    if cube(number) % 3 == 0:
        return True
        return False


you must check if number (not cube of number) is divisible by 3, if it is, return the result of calling cube on number (not True)


Ohhhh, thanks a lot. Now I can complete this lesson. Thank you very much!