Welcome to the CSC Q&A, on our server named in honor of Ada Lovelace. Write great code! Get help and give help!
It is our choices... that show what we truly are, far more than our abilities.

Categories

+20 votes
asked in CSC211_Winter2018 by (1 point)

1 Answer

+15 votes

Assuming that A is of type double and r and n are of type int...

double A = P*Math.pow((1+((r*1.0)/(n*1.0)), n*t);

There are other ways to do this, but that should do the trick.

answered by (1 point)
...