write a program to print the sum of the given series s=1+1+2+3+5+......... to n terms.
Answers
Answered by
0
Explanation:
in python3
# Python3 program to illustrate...
# Summation of series
import math
def summingSeries(n):
# Sum of n terms is n^2
return math.pow(n, 2)
# Driver Code
n = 100
print ("The sum of n term is: ",
summingSeries(n))
# This code is contributed by mits.
if you are pleased with answer then subscribe to my youtube channel ramakrishna Nallangari youtube channel you can do it by searching Nallangari in google
Similar questions