Psst.. new poll here.
Psst.. new forums here.
Microsoft is blocking us again (TY IP Reputation!) so just use oauth login instead. :)
Paste
Pasted as Java by Jodie ( 6 years ago )
double amount; // were calculating this: A=P(1+R)^n
double principal = 10000; //there are 10,000 people, this is the starting point
double rate = .01; // people is increasing by 1%
for(int day=1;day<=20;day++) {
amount=principal*Math.pow(1 + rate, day); //amount is 10,000 * 1% + rate ^ day (which is 20, thats how many days we want to see the results for)
System.out.println(day + " " + amount);
}
Revise this Paste
Parent: 112027
Children: 112029