Skip to content

Instantly share code, notes, and snippets.

@mojaie
Created December 2, 2011 09:03
Show Gist options
  • Save mojaie/1422439 to your computer and use it in GitHub Desktop.
Save mojaie/1422439 to your computer and use it in GitHub Desktop.
AOJ:0007
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner scn = new Scanner(System.in);
int n = scn.nextInt();
int debt = 100;
for (int i = 0; i < n; i++) {
debt = (int)Math.ceil(debt * 1.05);
}
System.out.println(debt * 1000);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment