157k views
1 vote
Write a function named cube that accepts a number as an argument and returns the cube of that number. Write Python statement(s) that passes 3 to this function and prints returned value.​

User Perculator
by
5.2k points

1 Answer

2 votes

def cube(num):

return num*num*num

for the number 3:

def cube():

return 3*3*3

User Vvekselva
by
5.4k points