In this article, we will learn to find the sum of the cube of the first n number using the python program.
the sum of the cube of n numbers:
13 + 23 + 33 + 43 + ....... + (n-1)3 + n3
We find the sum of the cube of positive numbers from 1 to nth using two method
- using for loop
- using mathematically