def cube(number):

return number ** 3

```
if by_three(n) / 3:
return cube(number)
else:
return False
```

by_three(number)

def cube(number):

return number ** 3

```
if by_three(n) / 3:
return cube(number)
else:
return False
```

by_three(number)

you should create a function named by_three, creating a function requires the `def`

keyword, look at how you created `cube`

function

def cube(number):

return number ** 3

def by_three(number):

if number / 3:

return cube

else:

return False

what do I return the first time in by three

better, but you need to return the `cube()`

of number is number is divisible by 3, to determine a number is divisble by three, you can check if the remainder equals zero, we can calculate the remainder using the modulo operator

what do you put for the argument of cube

def cube(number):

return number ** 3

def by_three(number):

if number % 3:

return cube()

else:

return False

cube()

number, given you want to return the cube of number

to check if a number is divisble by three, the remainder must **equal to zero**

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