Question: This is for python coding First of all, you need to know what Natural Numbers are. They are the positive integers (whole numbers) 1, 2,
This is for python coding
First of all, you need to know what Natural Numbers are. They are the positive integers (whole numbers) 1, 2, 3, etc., and zero as well.
For this project, there are TWO PORTIONS:
PORTION 1:
Write a program to find the SUM of the first n natural numbers the user wants to add.
The program should first prompt the user for how many natural numbers are to be summed. The use for loop to do the calculation. It should then print out a total sum.
PORTION 2:
Write a program to find the SUM of squares of the first n natural numbers the user wants to add.
The program should first prompt the user for how many natural numbers are to be summed. The use for loop to do the calculation. You can use math library function math.pow(x,y) to do the square. It should then print out a total sum.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
