Computer Science, asked by ajjayvenkatesh, 3 months ago

Write a program to find sum of the series: s= 1+a+a2+a3….+an.​

Answers

Answered by oshogarment
2

Answer:

Input: a = 3, n = 3

Output: 0.6666667

The series is 1/3 + 1/9 + 1/27 which is

equal to 0.6666667

Input: a = 5, n = 4

Output: 0.31039998

Explanation:

Answered by mohankumaarssm
1

Explanation:

Input: a = 3, n = 3

Output: 0.6666667

The series is 1/3 + 1/9 + 1/27 which is

equal to 0.6666667

Input: a = 5, n = 4

Output: 0.31039998

Similar questions