top of page
  • Subham Das

Sum of Natural Numbers

Sum of the 'n th' natural number using programming language. This program will print the series with the sum of the natural number. The series is:

1,2,3,4,5,6,7,8, ...................



# Program to print the series and the sum.

# Here enter number up to which the natural will print.

n = int(input("Enter number:"))

sum = 0

for i in range (1,n+1) :

sum += i

print(i, end=',')

print("Sum of the numbers :",sum)




3 views0 comments

Recent Posts

See All

Mathematical Series

There so many mathematical series. One of the series is given below. And we use different programming language to print the sum or the series in faster. Because calculating the sum is bit tougher. So

logo12.PNG
bottom of page