The formula to calculate compound interest is:
Where A is the total Amount, including all interest
P = the Principal (invested amount)
R = Rate of interest as a percentage
r = percentage as a decimal
n = time in years.
To find the amount of interest earned