Problem 566. Sum of first n terms of a harmonic progression
Given inputs a, d and n, return the sum of the first n terms of the harmonic progression a, a/(1+d), a/(1+2d), a/(1+3d),....
Solution Stats
Problem Comments
-
14 Comments
Show
11 older comments
mario alonzo
on 16 Jul 2018
This test has a problem with roundn function. I have also tried to use elseif and insert the exact values of s, but it doesn't work.
Srishti Saha
on 8 Aug 2018
@srivardhini Kindly look into the issue
goc3
on 10 Aug 2018
The test suite has been updated and the problem should function properly now. Various recent solutions were tested and did work. Feel free to resubmit prior solutions.
Solution Comments
Show commentsProblem Recent Solvers436
Suggested Problems
-
Return the largest number that is adjacent to a zero
5401 Solvers
-
1328 Solvers
-
How to find the position of an element in a vector without using the find function
2744 Solvers
-
10340 Solvers
-
Back to basics 23 - Triangular matrix
1026 Solvers
More from this Author1
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!