Question #267156

Sample Input 2

2000


Sample Output 2

2200

write a JS function to return the final value finalValue with the given appreciation percentage and time period. The default values for time and apprPercentage are 2 and 5 respectively.

Quick Tip

The formula to calculate the final value with appreciation is,

finalValue = principal * (1 + time * appreciation / 100)



1
Expert's answer
2021-11-16T18:33:49-0500
function finalValueAppreciation(principal, time = 2, appreciation = 5) {
    return principal * (1 + time * appreciation / 100)
}

console.log( finalValueAppreciation(100023) );
console.log( finalValueAppreciation(3000) );

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!
LATEST TUTORIALS
APPROVED BY CLIENTS