Problem 44143. Percentage profit:6: Cumulative Interest

Solution 1527461

Submitted on 13 May 2018 by William
This solution is locked. To view this solution, you need to provide a solution of the same size or smaller.

Test Suite

Test Status Code Input and Output
1   Pass
x=100; n=1; r=12.683; y_correct = 101; assert(isequal(your_fcn_name(r,x,n),y_correct))

2   Pass
x=200; n=1; r=12.683; y_correct = 202; assert(isequal(your_fcn_name(r,x,n),y_correct))

3   Pass
x=100; r=1; n=12; y_correct = 1206; assert(isequal(your_fcn_name(r,x,n),y_correct))

4   Pass
x=50; r=10; n=60; y_correct = 3859; assert(isequal(your_fcn_name(r,x,n),y_correct))

5   Pass
x=5; r=10; n=60; y_correct = 386; assert(isequal(your_fcn_name(r,x,n),y_correct))

6   Pass
x=100; r=14; n=360; y_correct = 459962; assert(isequal(your_fcn_name(r,x,n),y_correct))

Suggested Problems

More from this Author5

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!