Indentation


#1


Can someone tell me what is wrong about the indentation?


    def cube(n):
        return n*n*n
    def by_three(n):
        if n % 3 == 0:
            return cube(n)            
        else:
            return false


#2

Your indention is fine as far as compared to my code. You need number I believe instead of n but your indention syntax looks great. Also might want to capitolize your boolean false to False.


#3

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