Computer Science, asked by hunterrr, 1 year ago

write a program in Python to print the sum of the following series: s=1+x+x^2+x^3+.....+x^n

Answers

Answered by muhib43
0

Your answer will be

Is the 1

Answered by abinashdash600
0

Answer:

n=int(input('write no. of terms '))

x=int(input('write value of x '))

sum=1

while n>0:

      sum=sum+x(star)(star)n

      n=n-1

print(sum)

explanation:

star = asterisk

Similar questions