Answer:
def sum_cubes(n):
if n == 1:
return 1
else:
return n * n * n + sum_cubes(n-1)
print(sum_cubes(3))
Explanation:
Create a function called sum_cubes that takes one parameter, n
If n is equal to 1, return 1. Otherwise, calculate the cube of n, and add it to the sum_cubes function with parameter n-1
If we want to calculate the cubes of the first 3 numbers:
sum_cubes(3) = 3*3*3 + sum_cubes(2)
sum_cubes(2) = 2*2*2 + sum_cubes(1)
sum_cubes(1) = 1
If you substitute the values from the bottom, you get 27+8+1 = 36
Larry Page and Sergey Brin
Are the persons that invented google. This is funny Because is was after googol. mathematically founded by Edward Kasner and James Newman.
Hopes this helps!
technology has been very important in my life because, it helps me with my daily struggles, helps with stress (social media), makes everything easier, also creates a more efficient way of learning and much more.
although this should be answered with your own thoughts and opinions, I provided mine if in any case that it helps
D. Large sets of information that can be analyzed for patterns and trends