buggy_code
stringlengths 11
625k
| fixed_code
stringlengths 17
625k
| bug_type
stringlengths 2
4.45k
| language
int64 0
8
| token_count
int64 5
200k
| change_count
int64 0
100
|
|---|---|---|---|---|---|
char b, *p = &b;
main(i) {
~i ? main(*p-- = getchar()) : puts(p + 3);
exit(0);
}
|
char b[30], *p = b + 25;
main(i) {
~i ? main(*p-- = getchar()) : puts(p + 3);
exit(0);
}
|
[["+", 36, 36, 0, 30, 0, 43, 49, 80, 0, 70], ["+", 36, 36, 0, 30, 0, 43, 49, 80, 81, 13], ["+", 36, 36, 0, 30, 0, 43, 49, 80, 0, 73], ["-", 0, 30, 0, 43, 49, 50, 51, 66, 17, 67], ["+", 0, 30, 0, 43, 49, 50, 51, 16, 17, 72], ["+", 0, 30, 0, 43, 49, 50, 51, 16, 12, 13]]
| 0
| 41
| 6
|
# -*- coding: utf-8 -*-
import sys
for line in sys.stdin.readlines():
#List = map(int, line.strip().split())
seq = line.split()
print(seq[::-1])
|
# -*- coding: utf-8 -*-
import sys
for line in sys.stdin.readlines():
#List = map(int, line.strip().split())
seq = line.strip()
print(seq[::-1])
|
[["-", 0, 1, 0, 662, 12, 652, 63, 319, 319, 22], ["+", 0, 1, 0, 662, 12, 652, 63, 319, 319, 22]]
| 5
| 32
| 2
|
var debt = 100;
var wk = ~~(require('fs').readFileSync('/dev/stdin', 'utf8'));
for (; wk--;) {
debt = ~~(debt * 1.05) + 1;
}
console.log(debt * 1000);
|
var debt = 100;
var wk = ~~(require('fs').readFileSync('/dev/stdin', 'utf8'));
for (; wk--;) {
debt = Math.ceil(debt * 1.05);
}
console.log(debt * 1000);
|
[["-", 0, 1, 0, 11, 12, 16, 31, 91, 17, 92], ["-", 0, 11, 12, 16, 31, 91, 28, 91, 17, 92], ["+", 0, 1, 0, 11, 12, 2, 63, 558, 500, 22], ["+", 0, 1, 0, 11, 12, 2, 63, 558, 0, 131], ["+", 0, 1, 0, 11, 12, 2, 63, 558, 559, 560], ["-", 8, 556, 0, 1, 0, 11, 12, 16, 17, 72], ["-", 8, 556, 0, 1, 0, 11, 12, 16, 12, 555]]
| 2
| 60
| 7
|
function Main(input) {
var n = parseInt(input.split('\n')[0]), a = 100;
while (n--)
a += Math.ceil(a * 5 / 100);
console.log(a * 100);
}
Main(require("fs").readFileSync("/dev/stdin", "utf8"));
|
function Main(input) {
var n = parseInt(input.split('\n')[0]), a = 100;
while (n--)
a = Math.ceil(a * 1.05);
console.log(a * 1000);
}
Main(require("fs").readFileSync("/dev/stdin", "utf8"));
|
[["-", 8, 556, 0, 52, 8, 1, 0, 564, 17, 107], ["+", 8, 556, 0, 52, 8, 1, 0, 11, 0, 32], ["-", 12, 2, 3, 3, 0, 16, 31, 16, 12, 555], ["-", 0, 564, 12, 2, 3, 3, 0, 16, 17, 85], ["-", 0, 564, 12, 2, 3, 3, 0, 16, 12, 555], ["+", 0, 11, 12, 2, 3, 3, 0, 16, 12, 555], ["-", 0, 1, 0, 2, 3, 3, 0, 16, 12, 555], ["+", 0, 1, 0, 2, 3, 3, 0, 16, 12, 555]]
| 2
| 77
| 8
|
import java.util.*;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int n = sc.nextInt();
int money = 100000;
for (int i = 0; i < n; i++)
money *= 1.05;
{
if (money % 10000 != 0) {
money += 10000 - money % 10000;
}
}
System.out.println(money);
}
}
|
import java.util.*;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int n = sc.nextInt();
int money = 100000;
for (int i = 0; i < n; i++) {
money *= 1.05;
if (money % 1000 != 0) {
money += 1000 - money % 1000;
}
}
System.out.println(money);
}
}
|
[["+", 0, 195, 8, 196, 0, 7, 8, 196, 0, 45], ["-", 8, 498, 0, 195, 8, 196, 0, 196, 0, 45], ["-", 0, 57, 15, 15, 0, 16, 31, 16, 12, 499], ["+", 0, 57, 15, 15, 0, 16, 31, 16, 12, 499], ["-", 64, 196, 0, 1, 0, 11, 12, 16, 31, 499], ["+", 64, 196, 0, 1, 0, 11, 12, 16, 31, 499], ["-", 0, 1, 0, 11, 12, 16, 12, 16, 12, 499], ["+", 0, 1, 0, 11, 12, 16, 12, 16, 12, 499]]
| 3
| 96
| 8
|
import java.util.Scanner;
public class Main {
public static void main(String args[]) {
double debt = 100000.0;
int nWeeks = new Scanner(System.in).nextInt();
for (int i = 0; i < nWeeks; i++) {
debt = Math.ceil(debt * 0.00105) * 1000.0;
}
System.out.println(debt);
}
}
|
import java.util.Scanner;
public class Main {
public static void main(String args[]) {
double debt = 100000.0;
int nWeeks = new Scanner(System.in).nextInt();
for (int i = 0; i < nWeeks; i++) {
debt = Math.ceil(debt * 0.00105) * 1000.0;
}
System.out.println((int)debt);
}
}
|
[["+", 0, 1, 0, 492, 3, 4, 0, 74, 0, 24], ["+", 0, 492, 3, 4, 0, 74, 39, 506, 0, 507], ["+", 0, 1, 0, 492, 3, 4, 0, 74, 0, 25]]
| 3
| 82
| 13
|
import java.util.Scanner;
public class Main {
public static void main(String args[]) {
double debt = 100000.0;
int nWeeks = new Scanner(System.in).nextInt();
for (int i = 0; i < nWeeks; i++) {
debt = ((int)(debt * 0.00105 + 0.9)) * 1000.0;
}
System.out.println((int)debt);
}
}
|
import java.util.Scanner;
public class Main {
public static void main(String args[]) {
double debt = 100000.0;
int nWeeks = new Scanner(System.in).nextInt();
for (int i = 0; i < nWeeks; i++) {
debt = ((int)(debt * 0.00105 + 0.99)) * 1000.0;
}
System.out.println((int)debt);
}
}
|
[["-", 31, 23, 0, 74, 51, 23, 0, 16, 12, 515], ["+", 31, 23, 0, 74, 51, 23, 0, 16, 12, 515]]
| 3
| 89
| 2
|
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.math.BigDecimal;
public class Main {
public static void main(String[] args) { print(); }
public static void print() {
try {
BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
String str = br.readLine();
int weeks = Integer.parseInt(str);
int debt = 100000;
for (int i = 0; i < weeks; i++) {
debt = new BigDecimal(debt * 1.05)
.setScale(-1, BigDecimal.ROUND_CEILING)
.intValueExact();
}
System.out.println(debt);
} catch (IOException e) {
e.printStackTrace();
}
}
}
|
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.math.BigDecimal;
public class Main {
public static void main(String[] args) { print(); }
public static void print() {
try {
BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
String str = br.readLine();
int weeks = Integer.parseInt(str);
int debt = 100000;
for (int i = 0; i < weeks; i++) {
debt = new BigDecimal(debt * 1.05)
.setScale(-3, BigDecimal.ROUND_CEILING)
.intValueExact();
}
System.out.println(debt);
} catch (IOException e) {
e.printStackTrace();
}
}
}
|
[["-", 12, 492, 500, 492, 3, 4, 0, 91, 439, 499], ["+", 12, 492, 500, 492, 3, 4, 0, 91, 439, 499]]
| 3
| 161
| 2
|
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.util.Scanner;
import java.util.StringTokenizer;
public class Main {
static InputReader in;
static PrintWriter out;
static class Solution {
void solve() throws IOException {
int n = in.nextInt();
int debt = 100000;
for (int i = 0; i < n; i++) {
debt *= 105;
if (debt % 10 != 0) {
debt = debt / 100 / 1000;
debt = debt * 1000 + 1000;
} else {
debt /= 100;
}
}
out.println(debt);
// End solve()
}
// End Solution
}
public static void main(String[] args) throws IOException {
in = new InputReader(System.in);
out = new PrintWriter(System.out);
Solution solver = new Solution();
solver.solve();
out.close();
}
static class InputReader {
public BufferedReader br;
public StringTokenizer st;
public InputReader(InputStream stream) {
br = new BufferedReader(new InputStreamReader(stream));
}
public int nextInt() throws IOException {
while (st == null || !st.hasMoreTokens()) {
st = new StringTokenizer(br.readLine());
}
return Integer.parseInt(st.nextToken());
}
public long nextLong() throws IOException {
while (st == null || !st.hasMoreTokens()) {
st = new StringTokenizer(br.readLine());
}
return Long.parseLong(st.nextToken());
}
public String next() throws IOException {
while (st == null || !st.hasMoreTokens()) {
st = new StringTokenizer(br.readLine());
}
return st.nextToken();
}
public double nextDouble() throws IOException {
while (st == null || !st.hasMoreTokens()) {
st = new StringTokenizer(br.readLine());
}
return Double.parseDouble(st.nextToken());
}
}
}
|
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.util.Scanner;
import java.util.StringTokenizer;
public class Main {
static InputReader in;
static PrintWriter out;
static class Solution {
void solve() throws IOException {
int n = in.nextInt();
long debt = 100000;
for (int i = 0; i < n; i++) {
debt *= 105;
if (debt % 100000 != 0) {
debt = debt / 100000;
debt = debt * 1000 + 1000;
} else {
debt /= 100;
}
}
out.println(debt);
// End solve()
}
// End Solution
}
public static void main(String[] args) throws IOException {
in = new InputReader(System.in);
out = new PrintWriter(System.out);
Solution solver = new Solution();
solver.solve();
out.close();
}
static class InputReader {
public BufferedReader br;
public StringTokenizer st;
public InputReader(InputStream stream) {
br = new BufferedReader(new InputStreamReader(stream));
}
public int nextInt() throws IOException {
while (st == null || !st.hasMoreTokens()) {
st = new StringTokenizer(br.readLine());
}
return Integer.parseInt(st.nextToken());
}
public long nextLong() throws IOException {
while (st == null || !st.hasMoreTokens()) {
st = new StringTokenizer(br.readLine());
}
return Long.parseLong(st.nextToken());
}
public String next() throws IOException {
while (st == null || !st.hasMoreTokens()) {
st = new StringTokenizer(br.readLine());
}
return st.nextToken();
}
public double nextDouble() throws IOException {
while (st == null || !st.hasMoreTokens()) {
st = new StringTokenizer(br.readLine());
}
return Double.parseDouble(st.nextToken());
}
}
}
|
[["-", 0, 195, 8, 196, 0, 503, 39, 506, 0, 507], ["+", 0, 195, 8, 196, 0, 503, 39, 506, 0, 96], ["-", 0, 57, 15, 15, 0, 16, 31, 16, 12, 499], ["+", 0, 57, 15, 15, 0, 16, 31, 16, 12, 499], ["-", 0, 1, 0, 11, 12, 16, 31, 16, 17, 85], ["-", 0, 1, 0, 11, 12, 16, 31, 16, 12, 499], ["-", 64, 196, 0, 1, 0, 11, 12, 16, 12, 499], ["+", 64, 196, 0, 1, 0, 11, 12, 16, 12, 499]]
| 3
| 425
| 8
|
import java.util.*;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int n = sc.nextInt();
int result = 100000;
for (int i = 0; i < n; i++) {
result += result * 0.05;
}
result = (int)Math.ceil((double)result / 10000) * 10000;
System.out.println(result);
}
}
|
import java.util.*;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int n = sc.nextInt();
int result = 100000;
for (int i = 0; i < n; i++) {
result += result * 0.05;
result = (int)Math.ceil((double)result / 1000) * 1000;
}
System.out.println(result);
}
}
|
[["-", 0, 195, 8, 196, 0, 7, 8, 196, 0, 46], ["-", 31, 74, 51, 492, 3, 4, 0, 16, 12, 499], ["+", 31, 74, 51, 492, 3, 4, 0, 16, 12, 499], ["-", 8, 196, 0, 1, 0, 11, 12, 16, 12, 499], ["+", 8, 196, 0, 1, 0, 11, 12, 16, 12, 499], ["+", 0, 195, 8, 196, 0, 7, 8, 196, 0, 46]]
| 3
| 99
| 6
|
import java.util.Scanner;
public class Main {
public static void main(String[] args) throws Exception {
Scanner sc = new Scanner(System.in);
int n = sc.nextInt();
double l = 100000;
for (int i = 1; i <= n; i++) {
l *= 1.05;
if (l % 1000 != 0) {
l += (1000 - (l % 1000));
}
}
System.out.println(l);
}
}
|
import java.util.Scanner;
public class Main {
public static void main(String[] args) throws Exception {
Scanner sc = new Scanner(System.in);
int n = sc.nextInt();
double l = 100000;
for (int i = 1; i <= n; i++) {
l *= 1.05;
if (l % 1000 != 0) {
l += (1000 - (l % 1000));
}
}
System.out.println((long)l);
}
}
|
[["+", 0, 1, 0, 492, 3, 4, 0, 74, 0, 24], ["+", 0, 492, 3, 4, 0, 74, 39, 506, 0, 96], ["+", 0, 1, 0, 492, 3, 4, 0, 74, 0, 25]]
| 3
| 102
| 3
|
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.Scanner;
public class Main {
// http://judge.u-aizu.ac.jp/onlinejudge/description.jsp?id=0007&lang=jp
public static void main(String args[])
throws NumberFormatException, IOException {
BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
int n = Integer.parseInt(br.readLine());
double result = 100;
for (int i = 0; i < n; i++) {
result = Math.ceil(result * 1.05);
}
System.out.println(result * 1000);
}
}
|
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.Scanner;
public class Main {
// http://judge.u-aizu.ac.jp/onlinejudge/description.jsp?id=0007&lang=jp
public static void main(String args[])
throws NumberFormatException, IOException {
BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
int n = Integer.parseInt(br.readLine());
double result = 100;
for (int i = 0; i < n; i++) {
result = Math.ceil(result * 1.05);
}
System.out.println((int)result * 1000);
}
}
|
[["+", 0, 492, 3, 4, 0, 16, 31, 74, 0, 24], ["+", 3, 4, 0, 16, 31, 74, 39, 506, 0, 507], ["+", 0, 492, 3, 4, 0, 16, 31, 74, 0, 25]]
| 3
| 122
| 3
|
import java.io.*;
class Main {
public static void main(String[] args) throws IOException {
BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
int n = Integer.parseInt(br.readLine());
double result = 100000;
for (int i = 0; i < n; i++) {
result *= 1.05;
}
result = Math.ceil(result / 1000) * 1000;
System.out.println((int)result);
}
}
|
import java.io.*;
class Main {
public static void main(String[] args) throws IOException {
BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
int n = Integer.parseInt(br.readLine());
double result = 100000;
for (int i = 0; i < n; i++) {
result *= 1.05;
result = Math.ceil(result / 1000) * 1000;
}
System.out.println((int)result);
}
}
|
[["-", 0, 195, 8, 196, 0, 7, 8, 196, 0, 46], ["+", 0, 195, 8, 196, 0, 7, 8, 196, 0, 46]]
| 3
| 104
| 2
|
import java.util.*;
public class Main {
private static final Scanner scan = new Scanner(System.in);
public static void main(String[] args) {
int n = scan.nextInt();
long mon = 100_000;
for (int i = 0; i < n; i++) {
mon = (long)Math.ceil(mon * 1.05);
}
System.out.printf("%d\n", mon);
}
}
|
import java.util.*;
public class Main {
private static final Scanner scan = new Scanner(System.in);
public static void main(String[] args) {
int n = scan.nextInt();
long mon = 100_000;
for (int i = 0; i < n; i++) {
mon = (long)Math.ceil(mon * 1.05 / 1000.0) * 1000;
}
System.out.printf("%d\n", mon);
}
}
|
[["+", 31, 74, 51, 492, 3, 4, 0, 16, 17, 85], ["+", 31, 74, 51, 492, 3, 4, 0, 16, 12, 515], ["+", 8, 196, 0, 1, 0, 11, 12, 16, 17, 48], ["+", 8, 196, 0, 1, 0, 11, 12, 16, 12, 499]]
| 3
| 96
| 4
|
import java.util.*;
public class Main {
private static final Scanner scan = new Scanner(System.in);
public static void main(String[] args) {
int n = scan.nextInt();
long mon = 100_000;
for (int i = 0; i < n; i++) {
mon = (long)Math.ceil(mon * 1.05);
}
System.out.printf("%d\n", mon);
}
}
|
import java.util.*;
public class Main {
private static final Scanner scan = new Scanner(System.in);
public static void main(String[] args) {
int n = scan.nextInt();
long mon = 100_000;
for (int i = 0; i < n; i++) {
mon = (long)Math.ceil(mon * 1.05 / 1000) * 1000;
}
System.out.printf("%d\n", mon);
}
}
|
[["+", 31, 74, 51, 492, 3, 4, 0, 16, 17, 85], ["+", 31, 74, 51, 492, 3, 4, 0, 16, 12, 499], ["+", 8, 196, 0, 1, 0, 11, 12, 16, 17, 48], ["+", 8, 196, 0, 1, 0, 11, 12, 16, 12, 499]]
| 3
| 96
| 4
|
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
double n = sc.nextInt();
double gp = 100000.0;
for (int i = 0; i < (int)n; i++) {
gp += gp * 0.05;
}
gp = (Math.ceil(gp / 10000)) * 10000;
System.out.println((int)gp);
}
}
|
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
double n = sc.nextInt();
double gp = 100000.0;
for (int i = 0; i < (int)n; i++) {
gp += gp * 0.05;
gp = (Math.ceil(gp / 1000)) * 1000;
}
System.out.println((int)gp);
}
}
|
[["-", 0, 195, 8, 196, 0, 7, 8, 196, 0, 46], ["-", 31, 23, 0, 492, 3, 4, 0, 16, 12, 499], ["+", 31, 23, 0, 492, 3, 4, 0, 16, 12, 499], ["-", 8, 196, 0, 1, 0, 11, 12, 16, 12, 499], ["+", 8, 196, 0, 1, 0, 11, 12, 16, 12, 499], ["+", 0, 195, 8, 196, 0, 7, 8, 196, 0, 46]]
| 3
| 101
| 6
|
import java.io.*;
class Main {
public static void main(String[] args) throws Exception {
BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
double x = Double.parseDouble(br.readLine());
double y = 100000;
long z = 0;
for (long i = 0; i < x; i++) {
y = y + (y * 1.05);
y = y / 1000;
y = Math.ceil(y);
y = y * 1000;
z = (long)y;
}
System.out.println(z);
}
}
|
import java.io.*;
class Main {
public static void main(String[] args) throws Exception {
BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
double x = Double.parseDouble(br.readLine());
double y = 100000;
long z = 0;
for (long i = 0; i < x; i++) {
y = y + (y * 0.05);
y = y / 1000;
y = Math.ceil(y);
y = y * 1000;
z = (long)y;
}
System.out.println(z);
}
}
|
[["-", 0, 11, 12, 16, 12, 23, 0, 16, 12, 515], ["+", 0, 11, 12, 16, 12, 23, 0, 16, 12, 515]]
| 3
| 127
| 2
|
import java.math.BigDecimal;
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
int num = 100000;
int syuu = 0;
double goukei = 0;
double risi = 0;
Scanner scan = new Scanner(System.in);
syuu = scan.nextInt();
for (int i = 0; i < syuu; i++) {
risi = num * 0.05;
num = num + (int)risi;
risi = 0;
}
BigDecimal bd = new BigDecimal(num);
bd = bd.setScale(-3, BigDecimal.ROUND_UP);
num = (int)bd.doubleValue();
System.out.println(num);
}
}
|
import java.math.BigDecimal;
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
int num = 100000;
int syuu = 0;
double goukei = 0;
double risi = 0;
Scanner scan = new Scanner(System.in);
syuu = scan.nextInt();
for (int i = 0; i < syuu; i++) {
risi = num * 0.05;
num = num + (int)risi;
risi = 0;
BigDecimal bd = new BigDecimal(num);
bd = bd.setScale(-3, BigDecimal.ROUND_UP);
num = (int)bd.doubleValue();
}
// BigDecimal bd = new BigDecimal(num);
// bd = bd.setScale(-3, BigDecimal.ROUND_UP);
// num = (int)bd.doubleValue();
System.out.println(num);
}
}
|
[["-", 0, 195, 8, 196, 0, 7, 8, 196, 0, 46], ["+", 0, 195, 8, 196, 0, 7, 8, 196, 0, 46]]
| 3
| 148
| 2
|
import java.io.*;
class Main {
public static void main(String[] args) {
try {
BufferedReader br = new BufferedReader(
new InputStreamReader(System.in)); // ??\????????????????????????
String line = br.readLine();
int deptWeek = Integer.parseInt(line);
int dept = 100000;
for (int i = 0; i < deptWeek; i++) {
int checkDept = (int)(dept * 0.05);
dept = dept + checkDept;
String strCheckDept = String.valueOf(dept);
String num = strCheckDept.substring(strCheckDept.length() - 4,
strCheckDept.length());
if (!num.equals("0000")) {
int numnum = Integer.parseInt(num);
dept = dept + 10000 - numnum;
}
}
System.out.println(dept);
} catch (Exception e) {
e.printStackTrace();
}
}
}
|
import java.io.*;
class Main {
public static void main(String[] args) {
try {
BufferedReader br = new BufferedReader(
new InputStreamReader(System.in)); // ??\????????????????????????
String line = br.readLine();
int deptWeek = Integer.parseInt(line);
int dept = 100000;
for (int i = 0; i < deptWeek; i++) {
int checkDept = (int)(dept * 0.05);
dept = dept + checkDept;
String strCheckDept = String.valueOf(dept);
String num = strCheckDept.substring(strCheckDept.length() - 3,
strCheckDept.length());
if (!num.equals("000")) {
int numnum = Integer.parseInt(num);
dept = dept + 1000 - numnum;
}
}
System.out.println(dept);
} catch (Exception e) {
e.printStackTrace();
}
}
}
|
[["-", 49, 200, 51, 492, 3, 4, 0, 16, 12, 499], ["+", 49, 200, 51, 492, 3, 4, 0, 16, 12, 499], ["-", 0, 91, 439, 492, 3, 4, 0, 5, 0, 491], ["+", 0, 91, 439, 492, 3, 4, 0, 5, 0, 491], ["-", 0, 1, 0, 11, 12, 16, 31, 16, 12, 499], ["+", 0, 1, 0, 11, 12, 16, 31, 16, 12, 499]]
| 3
| 186
| 6
|
import java.io.*;
class Main {
public static void main(String[] args) {
try {
BufferedReader br = new BufferedReader(
new InputStreamReader(System.in)); // ??\????????????????????????
String line = br.readLine();
// ????????????????????´?????????
// String line; // ??\???????????????????????\???
// while ((line = br.readLine()) != null) {
// processLine(line);
// }
double initialValue = 100000.0;
for (int i = 0; i < Integer.valueOf(line); i++) {
double interest = initialValue * 0.05;
initialValue = initialValue + interest;
initialValue = initialValue / 1000;
initialValue = Math.ceil(initialValue);
initialValue = initialValue * 1000;
}
System.out.println(initialValue);
} catch (Exception e) {
e.printStackTrace();
}
}
// private static void processLine(String line) {
// System.out.println(line);
// }
}
|
import java.io.*;
class Main {
public static void main(String[] args) {
try {
BufferedReader br = new BufferedReader(
new InputStreamReader(System.in)); // ??\????????????????????????
String line = br.readLine();
// ????????????????????´?????????
// String line; // ??\???????????????????????\???
// while ((line = br.readLine()) != null) {
// processLine(line);
// }
double initialValue = 100000.0;
for (int i = 0; i < Integer.valueOf(line); i++) {
double interest = initialValue * 0.05;
initialValue = initialValue + interest;
initialValue = initialValue / 1000;
initialValue = Math.ceil(initialValue);
initialValue = initialValue * 1000;
}
System.out.println((int)initialValue);
} catch (Exception e) {
e.printStackTrace();
}
}
// private static void processLine(String line) {
// System.out.println(line);
// }
}
|
[["+", 0, 1, 0, 492, 3, 4, 0, 74, 0, 24], ["+", 0, 492, 3, 4, 0, 74, 39, 506, 0, 507], ["+", 0, 1, 0, 492, 3, 4, 0, 74, 0, 25]]
| 3
| 141
| 3
|
import java.util.Scanner;
class Main {
public static void main(String[] args) {
Scanner s = new Scanner(System.in);
int n = s.nextInt();
double debt = 100000;
for (int i = 1; i <= n; i++) {
debt = (debt * 1.05) / 1000;
debt = Math.ceil(debt) * 1000;
}
System.out.println(debt);
}
}
|
import java.util.Scanner;
class Main {
public static void main(String[] args) {
Scanner s = new Scanner(System.in);
int n = s.nextInt();
double debt = 100000;
for (int i = 1; i <= n; i++) {
debt = (debt * 1.05) / 1000;
debt = Math.ceil(debt) * 1000;
}
System.out.println((int)debt);
}
}
|
[["+", 0, 1, 0, 492, 3, 4, 0, 74, 0, 24], ["+", 0, 492, 3, 4, 0, 74, 39, 506, 0, 507], ["+", 0, 1, 0, 492, 3, 4, 0, 74, 0, 25]]
| 3
| 94
| 3
|
import static java.lang.System.*;
import java.util.*;
import java.util.stream.Collectors;
public class Main extends CodingSupport {
protected void solve() {
int input = scanInt();
double dept = 100000.0;
for (int i = 0; i < input; i++) {
dept = dept * 1.05;
if (dept % 1000 != 0) {
dept -= dept % 1000;
dept += 1000;
}
}
print(dept);
}
}
abstract class CodingSupport {
protected Scanner sc;
protected CodingSupport() { sc = new Scanner(in); }
public static void main(String[] args) throws Exception {
new Main().solve();
}
protected abstract void solve();
protected void print(Object o) { out.println(o); }
protected Double[] scanDoubles() {
return Arrays.stream(scanInts())
.map(Integer::doubleValue)
.toArray(Double[] ::new);
}
protected Integer[] scanInts() {
return strArrayToIntArray(sc.nextLine().split(" "));
}
protected String[] scanLineToTokens(String delimiter) {
return sc.nextLine().split(delimiter);
}
protected int scanInt() { return sc.nextInt(); }
protected List<Integer> strArrayToIntList(String[] strArray) {
List<Integer> intList = Arrays.stream(strArray)
.map(Integer::valueOf)
.collect(Collectors.toList());
return intList;
}
protected Integer[] strArrayToIntArray(String[] strArray) {
Integer[] intArray =
Arrays.stream(strArray).map(Integer::valueOf).toArray(Integer[] ::new);
return intArray;
}
}
|
import static java.lang.System.*;
import java.util.*;
import java.util.stream.Collectors;
public class Main extends CodingSupport {
protected void solve() {
int input = scanInt();
double dept = 100000.0;
for (int i = 0; i < input; i++) {
dept = dept * 1.05;
if (dept % 1000 != 0) {
dept -= dept % 1000;
dept += 1000;
}
}
print((int)dept);
}
}
abstract class CodingSupport {
protected Scanner sc;
protected CodingSupport() { sc = new Scanner(in); }
public static void main(String[] args) throws Exception {
new Main().solve();
}
protected abstract void solve();
protected void print(Object o) { out.println(o); }
protected Double[] scanDoubles() {
return Arrays.stream(scanInts())
.map(Integer::doubleValue)
.toArray(Double[] ::new);
}
protected Integer[] scanInts() {
return strArrayToIntArray(sc.nextLine().split(" "));
}
protected String[] scanLineToTokens(String delimiter) {
return sc.nextLine().split(delimiter);
}
protected int scanInt() { return sc.nextInt(); }
protected List<Integer> strArrayToIntList(String[] strArray) {
List<Integer> intList = Arrays.stream(strArray)
.map(Integer::valueOf)
.collect(Collectors.toList());
return intList;
}
protected Integer[] strArrayToIntArray(String[] strArray) {
Integer[] intArray =
Arrays.stream(strArray).map(Integer::valueOf).toArray(Integer[] ::new);
return intArray;
}
}
|
[["+", 0, 1, 0, 492, 3, 4, 0, 74, 0, 24], ["+", 0, 492, 3, 4, 0, 74, 39, 506, 0, 507], ["+", 0, 1, 0, 492, 3, 4, 0, 74, 0, 25]]
| 3
| 356
| 3
|
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner s = new Scanner(System.in);
int n = s.nextInt();
int m = 100000;
for (int i = 0; i < n; i++) {
m = Double.valueOf(Math.ceil((double)m * 1.05)).intValue();
int r = m % 1000;
if (r > 0) {
m += 100 - r;
}
}
System.out.println(m);
}
}
|
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner s = new Scanner(System.in);
int n = s.nextInt();
int m = 100000;
for (int i = 0; i < n; i++) {
m = Double.valueOf(Math.ceil((double)m * 1.05)).intValue();
int r = m % 1000;
if (r > 0) {
m += 1000 - r;
}
}
System.out.println(m);
}
}
|
[["-", 64, 196, 0, 1, 0, 11, 12, 16, 31, 499], ["+", 64, 196, 0, 1, 0, 11, 12, 16, 31, 499]]
| 3
| 118
| 2
|
import static java.lang.Math.*;
import static java.util.Arrays.*;
import java.util.*;
public class Main {
int INF = 1 << 28;
void run() {
Scanner sc = new Scanner(System.in);
int n = sc.nextInt();
int p = 100000;
for (int i = 0; i < n; i++) {
p = (int)(p * 1.05);
// System.out.println(p);
if (p % 1000 > 0)
p -= p % 1000 - 1000;
System.out.println(p);
}
// System.out.println(p);
}
public static void main(String[] args) { new Main().run(); }
void debug(Object... os) { System.err.println(Arrays.deepToString(os)); }
}
|
import static java.lang.Math.*;
import static java.util.Arrays.*;
import java.util.*;
public class Main {
int INF = 1 << 28;
void run() {
Scanner sc = new Scanner(System.in);
int n = sc.nextInt();
int p = 100000;
for (int i = 0; i < n; i++) {
p = (int)(p * 1.05);
// System.out.println(p);
if (p % 1000 > 0)
p -= p % 1000 - 1000;
// System.out.println(p);
}
System.out.println(p);
}
public static void main(String[] args) { new Main().run(); }
void debug(Object... os) { System.err.println(Arrays.deepToString(os)); }
}
|
[["+", 0, 195, 8, 196, 0, 7, 8, 196, 0, 46], ["-", 0, 195, 8, 196, 0, 7, 8, 196, 0, 46]]
| 3
| 168
| 2
|
import java.io.*;
public class Main {
public static void main(String[] args) throws IOException {
InputStreamReader is = new InputStreamReader(System.in);
BufferedReader br = new BufferedReader(is);
String str = br.readLine();
int n = Integer.parseInt(str);
double debt = 100.0;
for (int i = 0; i < n; i++) {
debt = debt * 1.05;
int deb = (int)debt;
double pre = debt;
pre = pre - (double)deb;
if (pre > 0.0)
deb++;
debt = (double)deb;
}
int deb = (int)debt;
deb *= 100;
System.out.println(deb);
}
}
|
import java.io.*;
public class Main {
public static void main(String[] args) throws IOException {
InputStreamReader is = new InputStreamReader(System.in);
BufferedReader br = new BufferedReader(is);
String str = br.readLine();
int n = Integer.parseInt(str);
double debt = 100.0;
for (int i = 0; i < n; i++) {
debt = debt * 1.05;
int deb = (int)debt;
double pre = debt;
pre = pre - (double)deb;
if (pre != 0.0)
deb++;
debt = (double)deb;
}
int deb = (int)debt;
deb *= 1000;
System.out.println(deb);
}
}
|
[["-", 8, 196, 0, 57, 15, 15, 0, 16, 17, 47], ["+", 8, 196, 0, 57, 15, 15, 0, 16, 17, 79], ["-", 0, 195, 8, 196, 0, 1, 0, 11, 12, 499], ["+", 0, 195, 8, 196, 0, 1, 0, 11, 12, 499]]
| 3
| 151
| 4
|
import java.util.*;
public class Main {
public static void main(String[] args) {
Scanner s = new Scanner(System.in);
int weeks = s.nextInt();
double debt = 100;
while (weeks > 0) {
debt = debt * 1.05;
debt = (int)Math.ceil(debt);
weeks--;
}
System.out.println((int)debt * 100);
}
}
|
import java.util.*;
public class Main {
public static void main(String[] args) {
Scanner s = new Scanner(System.in);
int weeks = s.nextInt();
double debt = 100;
while (weeks > 0) {
debt = debt * 1.05;
debt = (int)Math.ceil(debt);
weeks--;
}
System.out.println((int)debt * 1000);
}
}
|
[["-", 0, 1, 0, 492, 3, 4, 0, 16, 12, 499], ["+", 0, 1, 0, 492, 3, 4, 0, 16, 12, 499]]
| 3
| 92
| 2
|
import java.util.Scanner;
class Main {
public static void main(String[] args) {
int weeks = new Scanner(System.in).nextInt();
double debt = 100000;
for (int i = 0; i < 5; i++) {
debt *= 1.05;
double fraction = debt % 1000;
if (fraction != 0)
debt += 1000 - fraction;
}
System.out.println((long)debt);
}
}
|
import java.util.Scanner;
class Main {
public static void main(String[] args) {
int weeks = new Scanner(System.in).nextInt();
double debt = 100000;
for (int i = 0; i < weeks; i++) {
debt *= 1.05;
double fraction = debt % 1000;
if (fraction != 0)
debt += 1000 - fraction;
}
System.out.println((long)debt);
}
}
|
[["-", 0, 195, 8, 196, 0, 7, 15, 16, 12, 499], ["+", 0, 195, 8, 196, 0, 7, 15, 16, 12, 22]]
| 3
| 94
| 2
|
import java.util.*;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
while (sc.hasNext()) {
int n = sc.nextInt();
double debt = 100000;
for (int i = 0; i < n; i++) {
debt *= 1.05;
debt = (int)(debt / 1000) * 1000;
}
System.out.println((int)debt);
}
}
}
|
import java.util.*;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
while (sc.hasNext()) {
int n = sc.nextInt();
double debt = 100000;
for (int i = 0; i < n; i++) {
debt *= 1.05;
debt = Math.ceil(debt / 1000) * 1000;
}
System.out.println((int)debt);
}
}
}
|
[["-", 0, 1, 0, 11, 12, 16, 31, 74, 0, 24], ["-", 0, 11, 12, 16, 31, 74, 39, 506, 0, 507], ["-", 0, 1, 0, 11, 12, 16, 31, 74, 0, 25], ["+", 0, 1, 0, 11, 12, 16, 31, 492, 500, 22], ["+", 0, 1, 0, 11, 12, 16, 31, 492, 0, 131], ["+", 0, 1, 0, 11, 12, 16, 31, 492, 141, 22]]
| 3
| 104
| 6
|
import java.io.*;
class Main {
public static void main(String args[]) throws IOException {
BufferedReader input = new BufferedReader(new InputStreamReader(System.in));
double dept = 100000;
int n = Integer.parseInt(input.readLine());
for (int i = 0; i < n; i++) {
dept = dept * 1.05;
}
if ((int)(dept % 1000) > 0) {
dept = (int)(dept + 1000 - dept % 1000);
}
dept = (int)(dept - dept % 1000);
System.out.println((int)dept);
}
}
|
import java.io.*;
class Main {
public static void main(String args[]) throws IOException {
BufferedReader input = new BufferedReader(new InputStreamReader(System.in));
double dept = 100000;
int n = Integer.parseInt(input.readLine());
for (int i = 0; i < n; i++) {
dept = dept * 1.05;
if ((int)(dept % 1000) > 0) {
dept = (int)(dept + 1000 - dept % 1000);
}
}
dept = (int)(dept - dept % 1000);
System.out.println((int)dept);
}
}
|
[["-", 0, 195, 8, 196, 0, 7, 8, 196, 0, 46], ["+", 0, 7, 8, 196, 0, 57, 64, 196, 0, 46]]
| 3
| 136
| 2
|
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
int debt = 100000;
double interest = 0.05;
Scanner s = new Scanner(System.in);
int n = s.nextInt();
for (int i = 0; i < n; i++) {
debt += debt * interest;
}
debt = (int)Math.ceil((double)debt / 10000) * 10000;
System.out.println(debt);
}
}
|
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
int debt = 100000;
double interest = 0.05;
Scanner s = new Scanner(System.in);
int n = s.nextInt();
for (int i = 0; i < n; i++) {
debt += debt * interest;
debt = (int)Math.ceil((double)debt / 1000) * 1000;
}
System.out.println(debt);
}
}
|
[["-", 0, 195, 8, 196, 0, 7, 8, 196, 0, 46], ["-", 31, 74, 51, 492, 3, 4, 0, 16, 12, 499], ["+", 31, 74, 51, 492, 3, 4, 0, 16, 12, 499], ["-", 8, 196, 0, 1, 0, 11, 12, 16, 12, 499], ["+", 8, 196, 0, 1, 0, 11, 12, 16, 12, 499], ["+", 0, 195, 8, 196, 0, 7, 8, 196, 0, 46]]
| 3
| 104
| 6
|
import java.math.BigDecimal;
import java.util.Scanner;
public class Main {
static int calculate(int yen) {
BigDecimal bd = new BigDecimal(yen * 1.05);
BigDecimal bd1 = bd.setScale(-4, BigDecimal.ROUND_HALF_UP);
return bd1.intValue();
}
public static void main(String[] args) {
Scanner scan = new Scanner(System.in);
int n = scan.nextInt();
int yen = 100000;
for (int i = 0; i < n - 2; i++) {
yen = calculate(yen);
}
System.out.println(yen);
scan.close();
}
}
|
import java.math.BigDecimal;
import java.util.Scanner;
public class Main {
static int calculate(int yen) {
BigDecimal bd = new BigDecimal(yen * 1.05);
BigDecimal bd1 = bd.setScale(-3, BigDecimal.ROUND_UP);
return bd1.intValue();
}
public static void main(String[] args) {
Scanner scan = new Scanner(System.in);
int n = scan.nextInt();
int yen = 100000;
for (int i = 0; i < n; i++) {
yen = calculate(yen);
}
System.out.println(yen);
scan.close();
}
}
|
[["-", 49, 200, 51, 492, 3, 4, 0, 91, 439, 499], ["+", 49, 200, 51, 492, 3, 4, 0, 91, 439, 499], ["-", 49, 200, 51, 492, 3, 4, 0, 509, 119, 22], ["+", 49, 200, 51, 492, 3, 4, 0, 509, 119, 22], ["-", 8, 196, 0, 7, 15, 16, 12, 16, 17, 33], ["-", 8, 196, 0, 7, 15, 16, 12, 16, 12, 499]]
| 3
| 138
| 6
|
#include <stdio.h>
int main(void) {
int r = 100000;
int n;
scanf("%d", &n);
for (int i = 0; i < n; i++) {
r = r * 1.05;
}
if (r % 1000 > 0) {
r = r / 1000 * 1000 + 1000;
}
printf("%d\n", r);
return 0;
}
|
#include <stdio.h>
int main(void) {
int r = 100000;
int n, i;
scanf("%d", &n);
for (i = 0; i < n; i++) {
r = r * 1.05;
if (r % 1000 > 0) {
r = r / 1000 * 1000 + 1000;
}
}
printf("%d\n", r);
return 0;
}
|
[["+", 0, 30, 0, 14, 8, 9, 0, 43, 0, 21], ["+", 0, 30, 0, 14, 8, 9, 0, 43, 49, 22], ["-", 0, 14, 8, 9, 0, 7, 10, 43, 39, 40], ["-", 0, 14, 8, 9, 0, 7, 8, 9, 0, 46], ["+", 0, 7, 8, 9, 0, 57, 64, 9, 0, 46]]
| 0
| 82
| 5
|
#include <stdio.h>
int main(void) {
int r = 100000, n;
scanf("%d", &n);
for (int i = 0; i < n; i++) {
r = r * 1.05;
if (r % 10000 > 0) {
r = r / 1000 * 1000 + 1000;
}
}
printf("%d\n", r);
return 0;
}
|
#include <stdio.h>
int main(void) {
int r = 100000;
int n;
scanf("%d", &n);
for (int i = 0; i < n; i++) {
r = r * 1.05;
if (r % 1000 > 0) {
r = r / 1000 * 1000 + 1000;
}
}
printf("%d\n", r);
return 0;
}
|
[["-", 0, 30, 0, 14, 8, 9, 0, 43, 0, 21], ["+", 0, 30, 0, 14, 8, 9, 0, 43, 0, 35], ["+", 0, 30, 0, 14, 8, 9, 0, 43, 39, 40], ["-", 0, 57, 15, 23, 0, 16, 31, 16, 12, 13], ["+", 0, 57, 15, 23, 0, 16, 31, 16, 12, 13]]
| 0
| 81
| 5
|
#include <stdio.h>
int main(void) {
int n;
int debt;
int i;
scanf("%d", &n);
debt = 100000;
for (i = 0; i < n; i++) {
debt += 5000;
if (debt / 1000 != 0) {
debt /= 1000;
debt += 1;
debt *= 1000;
}
}
printf("%d\n", debt);
return (0);
}
|
#include <stdio.h>
int main(void) {
int n;
int debt;
int i;
scanf("%d", &n);
debt = 100000;
for (i = 0; i < n; i++) {
debt *= 1.05;
if (debt % 1000 != 0) {
debt /= 1000;
debt += 1;
debt *= 1000;
}
}
printf("%d\n", debt);
return (0);
}
|
[["-", 0, 7, 8, 9, 0, 1, 0, 11, 17, 107], ["-", 0, 7, 8, 9, 0, 1, 0, 11, 12, 13], ["+", 0, 7, 8, 9, 0, 1, 0, 11, 17, 108], ["+", 0, 7, 8, 9, 0, 1, 0, 11, 12, 13], ["-", 0, 57, 15, 23, 0, 16, 31, 16, 17, 85], ["+", 0, 57, 15, 23, 0, 16, 31, 16, 17, 109]]
| 0
| 88
| 6
|
#include <stdio.h>
int main() {
int DEBT = 100000;
int i, n;
scanf("%d", &n);
for (i = 0; i <= n; i++) {
DEBT *= 1.05;
DEBT = (DEBT / 1000) * 1000;
}
printf("%d\n", DEBT);
return 0;
}
|
#include <stdio.h>
int main() {
int DEBT = 100000;
int i, n;
scanf("%d", &n);
for (i = 0; i < n; i++) {
DEBT *= 1.05;
DEBT = ((DEBT + 999) / 1000) * 1000;
}
printf("%d\n", DEBT);
return 0;
}
|
[["-", 0, 14, 8, 9, 0, 7, 15, 16, 17, 19], ["+", 0, 14, 8, 9, 0, 7, 15, 16, 17, 18], ["+", 0, 1, 0, 11, 12, 16, 31, 23, 0, 24], ["+", 31, 23, 0, 16, 31, 23, 0, 16, 17, 72], ["+", 31, 23, 0, 16, 31, 23, 0, 16, 12, 13], ["+", 12, 16, 31, 23, 0, 16, 31, 23, 0, 25]]
| 0
| 70
| 6
|
#include <stdio.h>
int main(void) {
int n;
int m = 100000;
int i;
scanf("%d", &n);
for (i = 0; i < n; i++) {
m *= 1.05;
}
m = (m % 1000 == 0 ? m : m - m % 10000 + 10000);
printf("%d\n", m);
return (0);
}
|
#include <stdio.h>
int main(void) {
int n;
int m = 100000;
int i;
scanf("%d", &n);
for (i = 0; i < n; i++) {
m *= 1.05;
m = (m % 1000 == 0 ? m : (m - m % 1000) + 1000);
}
printf("%d\n", m);
return (0);
}
|
[["-", 0, 14, 8, 9, 0, 7, 8, 9, 0, 46], ["+", 12, 23, 0, 41, 75, 16, 31, 23, 0, 24], ["-", 0, 41, 75, 16, 31, 16, 12, 16, 12, 13], ["+", 75, 16, 31, 23, 0, 16, 12, 16, 12, 13], ["+", 12, 23, 0, 41, 75, 16, 31, 23, 0, 25], ["-", 0, 11, 12, 23, 0, 41, 75, 16, 12, 13], ["+", 0, 11, 12, 23, 0, 41, 75, 16, 12, 13], ["+", 0, 14, 8, 9, 0, 7, 8, 9, 0, 46]]
| 0
| 84
| 8
|
#include <stdio.h>
int main() {
int debt = 100000;
int i, n;
scanf("%d", &n);
for (i = 0; i < n; i++) {
debt *= 1.05;
}
if (debt % 1000 != 0) {
debt = (debt / 1000 + 1) * 1000;
printf("%d\n", debt);
}
return 0;
}
|
#include <stdio.h>
int main() {
int debt = 100000;
int i, n;
scanf("%d", &n);
for (i = 0; i < n; i++) {
debt *= 1.05;
if (debt % 1000 != 0) {
debt = (debt / 1000 + 1) * 1000;
}
}
printf("%d\n", debt);
return 0;
}
|
[["-", 0, 14, 8, 9, 0, 7, 8, 9, 0, 46], ["+", 0, 7, 8, 9, 0, 57, 64, 9, 0, 46], ["+", 0, 14, 8, 9, 0, 7, 8, 9, 0, 46], ["-", 0, 14, 8, 9, 0, 57, 64, 9, 0, 46]]
| 0
| 82
| 4
|
#include <stdio.h>
int main(void) {
int n;
long int total = 100000;
scanf("%ld", &n);
for (; n > 0; n--) {
total *= 1.05;
if ((total % 1000) > 0)
total = (total / 1000 + 1) * 1000;
}
printf("%ld", total);
return 0;
}
|
#include <stdio.h>
int main(void) {
int n;
long int total = 100000;
scanf("%d", &n);
for (; n > 0; n--) {
total *= 1.05;
if ((total % 1000) > 0)
total = (total / 1000 + 1) * 1000;
}
printf("%ld\n", total);
return 0;
}
|
[["-", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44]]
| 0
| 78
| 3
|
#include <stdio.h>
int main(void) {
int i, j, money = 100000, debt, week, surplus;
scanf("%d", &week);
for (i = 0; i < week; i++) {
debt = money * 1.05;
surplus = debt % 1000;
// printf("%d\r\n", debt);
// printf("%d\r\n", surplus);
if (surplus) {
money = debt + 1000 - surplus;
}
money = debt;
}
printf("%d\r\n", debt);
return 0;
}
|
#include <stdio.h>
int main(void) {
int i, j, money = 100000, debt, week, surplus;
scanf("%d", &week);
for (i = 0; i < week; i++) {
debt = money * 1.05;
surplus = debt % 1000;
if (surplus) {
money = debt + 1000 - surplus;
} else {
money = debt;
}
}
printf("%d\r\n", money);
return 0;
}
|
[["+", 0, 7, 8, 9, 0, 57, 75, 76, 0, 95], ["+", 8, 9, 0, 57, 75, 76, 0, 9, 0, 45], ["+", 0, 14, 8, 9, 0, 7, 8, 9, 0, 46], ["-", 8, 9, 0, 1, 0, 2, 3, 4, 0, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 22]]
| 0
| 95
| 16
|
#include <stdio.h>
int main(void) {
int n;
int sum;
int i;
sum = 100000;
scanf("%d", &n);
for (i = 0; i < n; i++) {
sum *= 1.05;
}
if (sum % 10000 != 0) {
sum = (sum / 10000 + 1) * 10000;
}
printf("%d\n", sum);
return (0);
}
|
#include <stdio.h>
int main(void) {
int n;
int sum;
int i;
sum = 100000;
scanf("%d", &n);
for (i = 0; i < n; i++) {
sum *= 1.05;
if (sum % 1000 != 0) {
sum = (sum / 1000 + 1) * 1000;
}
}
printf("%d\n", sum);
return (0);
}
|
[["-", 0, 14, 8, 9, 0, 7, 8, 9, 0, 46], ["-", 0, 57, 15, 23, 0, 16, 31, 16, 12, 13], ["+", 0, 57, 15, 23, 0, 16, 31, 16, 12, 13], ["-", 12, 16, 31, 23, 0, 16, 31, 16, 12, 13], ["+", 12, 16, 31, 23, 0, 16, 31, 16, 12, 13], ["-", 64, 9, 0, 1, 0, 11, 12, 16, 12, 13], ["+", 64, 9, 0, 1, 0, 11, 12, 16, 12, 13], ["+", 0, 7, 8, 9, 0, 57, 64, 9, 0, 46]]
| 0
| 88
| 8
|
#include <stdio.h>
int debt_amount(int, int);
int main() {
int n;
scanf("%d", &n);
printf("%d\n", debt_amount(100000, n));
return 0;
}
int debt_amount(int a, int x) {
if (x >= 1) {
a = (a + a * 0.05) / 1000 + 0.9;
a = a * 1000;
return debt_amount(a, x - 1);
} else {
return a;
}
}
|
#include <stdio.h>
int debt_amount(int, int);
int main() {
int n;
scanf("%d", &n);
printf("%d\n", debt_amount(100000, n));
return 0;
}
int debt_amount(int a, int x) {
if (x >= 1) {
a = (a + a * 0.05 + 999) / 1000;
a = a * 1000;
return debt_amount(a, x - 1);
} else {
return a;
}
}
|
[["+", 0, 11, 12, 16, 31, 23, 0, 16, 17, 72], ["+", 0, 11, 12, 16, 31, 23, 0, 16, 12, 13], ["-", 64, 9, 0, 1, 0, 11, 12, 16, 17, 72], ["-", 64, 9, 0, 1, 0, 11, 12, 16, 12, 13]]
| 0
| 102
| 4
|
#include <stdio.h>
int main(void) {
int n, i;
int j = 100000.0;
scanf("%d", &n);
for (i = 0; i < n; i++)
j *= 1.05;
if (j % 1000 != 0) {
j = (j / 1000 + 1) * 1000;
}
printf("%d\n", j);
return 0;
}
|
#include <stdio.h>
int main(void) {
int n, i;
int j = 100000;
scanf("%d", &n);
for (i = 0; i < n; i++) {
j *= 1.05;
if (j % 1000 != 0) {
j = (j / 1000 + 1) * 1000;
}
}
printf("%d\n", j);
return 0;
}
|
[["-", 0, 14, 8, 9, 0, 43, 49, 50, 51, 13], ["+", 0, 14, 8, 9, 0, 43, 49, 50, 51, 13], ["+", 0, 14, 8, 9, 0, 7, 8, 9, 0, 45], ["+", 0, 7, 8, 9, 0, 57, 64, 9, 0, 46]]
| 0
| 81
| 4
|
#include <stdio.h>
int main(void) {
int money, i, n, k, num;
money = 100000;
scanf("%d", &n);
for (i = 0; i < n; i++) {
money *= 1.05;
num = money / 100;
k = money % 100;
if (k > 0) {
money = (num * 100) + 1000;
}
}
printf("%d\n", money);
return 0;
}
|
#include <stdio.h>
int main(void) {
int money, i, n, k, num;
money = 100000;
scanf("%d", &n);
for (i = 0; i < n; i++) {
money *= 1.05;
num = money / 1000;
k = money % 1000;
if (k > 0) {
money = (num * 1000) + 1000;
}
}
printf("%d\n", money);
return 0;
}
|
[["-", 8, 9, 0, 1, 0, 11, 12, 16, 12, 13], ["+", 8, 9, 0, 1, 0, 11, 12, 16, 12, 13], ["-", 0, 11, 12, 16, 31, 23, 0, 16, 12, 13], ["+", 0, 11, 12, 16, 31, 23, 0, 16, 12, 13]]
| 0
| 96
| 6
|
#include <stdio.h>
int n;
int answer = 100000;
int i;
int a, b;
int main(void) {
scanf("%d", &n);
{
for (i = 0; i < n; i++)
answer = answer * 1.05;
}
a = answer % 1000;
if (a != 0) {
answer = answer - a + 1000;
}
printf("%d\n", answer);
return 0;
}
|
#include <stdio.h>
int n;
int answer = 100000;
int i;
int a, b;
int main(void) {
scanf("%d", &n);
for (i = 0; i < n; i++) {
answer = answer * 1.05;
a = answer % 1000;
if (a != 0) {
answer = answer - a + 1000;
}
}
printf("%d\n", answer);
return 0;
}
|
[["-", 0, 30, 0, 14, 8, 9, 0, 9, 0, 45], ["+", 0, 14, 8, 9, 0, 7, 8, 9, 0, 45], ["-", 0, 30, 0, 14, 8, 9, 0, 9, 0, 46], ["+", 0, 7, 8, 9, 0, 57, 64, 9, 0, 46]]
| 0
| 91
| 4
|
#include <stdio.h>
int main(void) {
int n, i;
int x = 100000;
scanf("%d", &n);
for (i = 0; i < n; i++) {
x = x * 1.05;
}
if (x % 1000 != 0) {
x += 1000 - (x % 1000);
}
printf("%d\n", x);
return 0;
}
|
#include <stdio.h>
int main(void) {
int n, i;
int x = 100000;
scanf("%d", &n);
for (i = 0; i < n; i++) {
x = x * 1.05;
if (x % 1000 != 0) {
x += 1000 - (x % 1000);
}
}
printf("%d\n", x);
return 0;
}
|
[["-", 0, 14, 8, 9, 0, 7, 8, 9, 0, 46], ["+", 0, 7, 8, 9, 0, 57, 64, 9, 0, 46]]
| 0
| 83
| 2
|
#include <stdio.h>
int calc(int n);
int main() {
int n;
scanf("%d", &n);
printf("%d\n", calc(n));
return 0;
}
int calc(int n) {
int a;
a = 100000;
for (; n > 0; n--) {
a *= 1.05;
if (a % 1000 != 0) {
a = (a / 1000 + 1) * 1000;
}
}
}
|
#include <stdio.h>
int calc(int n);
int main() {
int n;
scanf("%d", &n);
printf("%d\n", calc(n));
return 0;
}
int calc(int n) {
int a;
a = 100000;
for (; n > 0; n--) {
a *= 1.05;
if (a % 1000 != 0) {
a = (a / 1000 + 1) * 1000;
}
}
return a;
}
|
[["+", 0, 30, 0, 14, 8, 9, 0, 37, 0, 38], ["+", 0, 30, 0, 14, 8, 9, 0, 37, 0, 22], ["+", 0, 30, 0, 14, 8, 9, 0, 37, 0, 35]]
| 0
| 97
| 3
|
#include <stdio.h>
int main(void) {
int n, i, mul = 100000;
scanf("%d", &n);
for (i = 1; i <= n; i++) {
mul *= 1.05;
}
if (mul % 1000 != 0) {
mul = mul - mul % 1000 + 1000;
}
printf("%d\n", mul);
return 0;
}
|
#include <stdio.h>
int main(void) {
int n, i, mul = 100000;
scanf("%d", &n);
for (i = 1; i <= n; i++) {
mul *= 1.05;
if (mul % 1000 != 0) {
mul = mul - mul % 1000 + 1000;
}
}
printf("%d\n", mul);
return 0;
}
|
[["-", 0, 14, 8, 9, 0, 7, 8, 9, 0, 46], ["+", 0, 7, 8, 9, 0, 57, 64, 9, 0, 46]]
| 0
| 80
| 2
|
/*
http://judge.u-aizu.ac.jp/onlinejudge/description.jsp?id=0007
Debt Hell
*/
#include <stdio.h>
int main(void) {
int n, i, debt, temp;
debt = 100000;
scanf("%d", &n);
for (i = 0; i < n; ++i) {
debt = debt * 1.05;
temp = debt % 1000;
if (debt != 0) {
debt = debt - temp + 1000;
}
}
printf("%d\n", debt);
return 0;
}
|
/*
http://judge.u-aizu.ac.jp/onlinejudge/description.jsp?id=0007
Debt Hell
*/
#include <stdio.h>
int main(void) {
int n, i, debt, temp;
debt = 100000;
scanf("%d", &n);
for (i = 0; i < n; ++i) {
debt = debt * 1.05;
temp = debt % 1000;
if (temp != 0) {
debt = debt - temp + 1000;
}
}
printf("%d\n", debt);
return 0;
}
|
[["-", 8, 9, 0, 57, 15, 23, 0, 16, 31, 22], ["+", 8, 9, 0, 57, 15, 23, 0, 16, 31, 22]]
| 0
| 89
| 2
|
#include <math.h>
#include <stdio.h>
int main(void) {
int n, i, s;
scanf("%d", &n);
s = 100000;
for (i = 0; i < n; i++) {
s *= 1.05;
if (s % 1000 != 0) {
s = (s / 10000) + 1 * 1000;
}
}
printf("%d\n", s);
return (0);
}
|
#include <math.h>
#include <stdio.h>
int main(void) {
int n, i, s;
scanf("%d", &n);
s = 100000;
for (i = 0; i < n; i++) {
s = s * 1.05;
if (s % 1000 != 0) {
s = (s / 1000 + 1) * 1000;
}
}
printf("%d\n", s);
return (0);
}
|
[["-", 0, 7, 8, 9, 0, 1, 0, 11, 17, 108], ["+", 0, 7, 8, 9, 0, 1, 0, 11, 17, 32], ["+", 8, 9, 0, 1, 0, 11, 12, 16, 31, 22], ["+", 8, 9, 0, 1, 0, 11, 12, 16, 17, 48], ["-", 0, 11, 12, 16, 31, 23, 0, 16, 12, 13], ["-", 0, 1, 0, 11, 12, 16, 31, 23, 0, 25], ["+", 12, 16, 31, 23, 0, 16, 31, 16, 12, 13], ["+", 0, 1, 0, 11, 12, 16, 31, 23, 0, 25]]
| 0
| 88
| 8
|
#include <stdio.h>
int main(void) {
int n;
int debt = 100000;
int i;
scanf("%d", &n);
for (i = 0; i < n; i++) {
debt *= 1.05;
if (debt % 1000 != 0) {
debt += -debt % 1000;
}
}
printf("%d\n", debt);
return 0;
}
|
#include <stdio.h>
int main(void) {
int n;
int debt = 100000;
int i;
scanf("%d", &n);
for (i = 0; i < n; i++) {
debt *= 1.05;
if (debt % 1000 != 0) {
debt += 1000 - debt % 1000;
}
}
printf("%d\n", debt);
return 0;
}
|
[["+", 64, 9, 0, 1, 0, 11, 12, 16, 31, 13]]
| 0
| 79
| 1
|
#include <stdio.h>
int main(void) {
int a = 100000;
int x, y, i;
scanf("%d", &x);
for (i = 0; i < x; i++) {
a = a * 1.05;
if (a % 100 != 0) {
a = a / 1000;
a = (a + 1) * 1000;
}
}
printf("%d\n", a);
return 0;
}
|
#include <stdio.h>
int main(void) {
int a = 100000;
int x, y, i;
scanf("%d", &x);
for (i = 0; i < x; i++) {
a = a * 1.05;
if (a % 1000 != 0) {
a = a / 1000;
a = (a + 1) * 1000;
}
}
printf("%d\n", a);
return 0;
}
|
[["-", 0, 57, 15, 23, 0, 16, 31, 16, 12, 13], ["+", 0, 57, 15, 23, 0, 16, 31, 16, 12, 13]]
| 0
| 91
| 2
|
#include <math.h>
#include <stdio.h>
int main(int argc, const char *argv[]) {
int n, i, money = 100000;
scanf("%d", &n);
for (i = 0; i < n; i++) {
money = money * 1.05;
}
if (money % 1000 != 0)
money = ceil(money / 10000 + 1) * 10000 + 0;
// money=(money/10000+1)*10000;
printf("%d\n", money);
return 0;
}
|
#include <math.h>
#include <stdio.h>
int main(int argc, const char *argv[]) {
int n, i, money = 100000;
scanf("%d", &n);
for (i = 0; i < n; i++) {
money = money * 1.05;
if (money % 1000 != 0)
money = ceil(money / 1000 + 1) * 1000;
}
printf("%d\n", money);
return 0;
}
|
[["-", 0, 14, 8, 9, 0, 7, 8, 9, 0, 46], ["-", 31, 2, 3, 4, 0, 16, 31, 16, 12, 13], ["+", 31, 2, 3, 4, 0, 16, 31, 16, 12, 13], ["-", 64, 1, 0, 11, 12, 16, 31, 16, 12, 13], ["-", 0, 57, 64, 1, 0, 11, 12, 16, 17, 72], ["-", 0, 57, 64, 1, 0, 11, 12, 16, 12, 13], ["+", 0, 57, 64, 1, 0, 11, 12, 16, 12, 13], ["+", 0, 14, 8, 9, 0, 7, 8, 9, 0, 46]]
| 0
| 96
| 8
|
#include <stdio.h>
main() {
int n, x = 100000, y, i;
scanf("%d", &n);
for (i = 0; i < n; i++) {
x *= 1.05;
}
y = x / 1000;
if (x - y * 1000 == 0)
x = y * 1000;
else
x = y * 1000 + 1000;
printf("%d\n", x);
return 0;
}
|
#include <stdio.h>
main() {
int n, x = 100000, y, i;
scanf("%d", &n);
for (i = 0; i < n; i++) {
x *= 1.05;
y = x / 1000;
if (x - y * 1000 == 0)
x = y * 1000;
else
x = y * 1000 + 1000;
}
printf("%d\n", x);
return 0;
}
|
[["-", 0, 30, 0, 9, 0, 7, 8, 9, 0, 46], ["+", 0, 30, 0, 9, 0, 7, 8, 9, 0, 46]]
| 0
| 92
| 2
|
n;
main(d) {
for (d = scanf("%d", &n) + 99; n -= 1; d = ceil(d * 1.05))
;
printf("%d\n", d * 1000);
}
|
n;
main(d) {
for (d = scanf("%d", &n) + 99; n--; d = ceil(d * 1.05))
;
exit(!printf("%d\n", d * 1000));
}
|
[["-", 0, 14, 8, 9, 0, 7, 15, 11, 17, 110], ["-", 0, 14, 8, 9, 0, 7, 15, 11, 12, 13], ["+", 0, 14, 8, 9, 0, 7, 15, 27, 17, 68], ["+", 0, 14, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 91, 17, 111], ["+", 3, 4, 0, 91, 28, 2, 3, 4, 0, 25]]
| 0
| 50
| 6
|
n;
main(d) {
for (d = scanf("%d", &n) + 99; n -= 1; d = ceil(d * 1.05))
;
printf("%d\n", d * 1000);
}
|
n;
main(d) {
for (d = scanf("%d", &n) + 99; n--; d = ceil(d * 1.05))
;
n = !printf("%d\n", d * 1000);
}
|
[["-", 0, 14, 8, 9, 0, 7, 15, 11, 17, 110], ["-", 0, 14, 8, 9, 0, 7, 15, 11, 12, 13], ["+", 0, 14, 8, 9, 0, 7, 15, 27, 17, 68], ["+", 0, 14, 8, 9, 0, 1, 0, 11, 31, 22], ["+", 0, 14, 8, 9, 0, 1, 0, 11, 17, 32], ["+", 8, 9, 0, 1, 0, 11, 12, 91, 17, 111]]
| 0
| 50
| 6
|
n;
main(d) {
for (d = scanf("%d", &n) + 99; n--; d = d * 1.05 + .9)
;
n = !printf("%d", d * 1000);
}
|
n;
main(d) {
for (d = scanf("%d", &n) + 99; n--; d = d * 1.05 + .99)
;
n = !printf("%d\n", d * 1000);
}
|
[["-", 8, 9, 0, 7, 26, 11, 12, 16, 12, 13], ["+", 8, 9, 0, 7, 26, 11, 12, 16, 12, 13], ["+", 12, 91, 28, 2, 3, 4, 0, 5, 0, 44]]
| 0
| 50
| 3
|
#include <stdio.h>
int main(void) {
double m;
int n;
long t;
m = 100000;
scanf("%ld", &n);
for (; n > 0; n--) {
m = m * 1.05;
t = m;
if (t % 1000 != 0)
m = m - t % 1000 + 1000;
}
printf("%ld\n", m);
return 0;
}
|
#include <stdio.h>
int main(void) {
long m;
int n;
long t;
m = 100000;
scanf("%d", &n);
for (; n > 0; n--) {
m = m * 1.05;
t = m;
if (t % 1000 != 0)
m = m - t % 1000 + 1000;
}
printf("%ld\n", m);
return 0;
}
|
[["-", 0, 30, 0, 14, 8, 9, 0, 43, 39, 40], ["+", 0, 14, 8, 9, 0, 43, 39, 86, 0, 96], ["-", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6]]
| 0
| 85
| 4
|
#include <stdio.h>
int main() {
int i, n, m;
m = 100000;
scanf("%d", &n);
for (i = 0; i < n; i++) {
m *= 1.05;
int a = m % 1000;
if (a != 0) {
m += 1000 - a;
}
printf("%d\n", (int)m);
}
return 0;
}
|
#include <stdio.h>
int main() {
int i, n, m;
m = 100000;
scanf("%d", &n);
for (i = 0; i < n; i++) {
m *= 1.05;
int a = m % 1000;
if (a != 0) {
m += 1000 - a;
}
}
printf("%d\n", (int)m);
return 0;
}
|
[["+", 0, 14, 8, 9, 0, 7, 8, 9, 0, 46], ["-", 0, 14, 8, 9, 0, 7, 8, 9, 0, 46]]
| 0
| 85
| 2
|
#include <stdio.h>
int main(void) {
int i, n, amount = 100000;
scanf("%d", &n);
for (i = 0; i < 5; i++) {
amount *= 1.05;
if (amount % 1000 != 0)
amount = amount - amount % 1000 + 1000;
}
printf("%d\n", amount);
return 0;
}
|
#include <stdio.h>
int main(void) {
int i, n, amount = 100000;
scanf("%d", &n);
for (i = 0; i < n; i++) {
amount *= 1.05;
if (amount % 1000 != 0)
amount = amount - amount % 1000 + 1000;
}
printf("%d\n", amount);
return 0;
}
|
[["-", 0, 14, 8, 9, 0, 7, 15, 16, 12, 13], ["+", 0, 14, 8, 9, 0, 7, 15, 16, 12, 22]]
| 0
| 78
| 2
|
#include <stdio.h>
#define DEBT 100000
#define INTEREST 0.05
#define ROUNDDEV 1000
int main(void) {
int w, i;
long int result = DEBT;
scanf("%d", &w);
for (i = 0; i < w; i++) {
result *= (INTEREST + 1.0);
result = ((result + (ROUNDDEV - ROUNDDEV / 10)) / ROUNDDEV) * ROUNDDEV;
}
printf("%ld\n", result);
return 0;
}
|
#include <stdio.h>
#define DEBT 100000
#define INTEREST 0.05
#define ROUNDDEV 1000
int main(void) {
int w, i;
long int result = DEBT;
scanf("%d", &w);
for (i = 0; i < w; i++) {
result *= (INTEREST + 1.0);
// printf("R*0.9=%ld\n",ROUNDDEV-ROUNDDEV/10);
// printf("r+R*0.9=%ld\n",result+(ROUNDDEV-ROUNDDEV/10));
// printf("(r+R*0.9)/R=%ld\n",(result+(ROUNDDEV-ROUNDDEV/10))/ROUNDDEV);
// printf("((r+R*0.9)/R)*R=%ld\n",((result+(ROUNDDEV-ROUNDDEV/10))/ROUNDDEV)*ROUNDDEV);
// if(result%ROUNDDEV!=0){
// result+=ROUNDDEV-(result%ROUNDDEV);
//}
result = ((result + (ROUNDDEV - 1)) / ROUNDDEV) * ROUNDDEV;
// printf("r=%ld\n",result);
}
printf("%ld\n", result);
return 0;
}
|
[["-", 0, 16, 12, 23, 0, 16, 12, 16, 31, 22], ["-", 0, 16, 12, 23, 0, 16, 12, 16, 17, 85], ["-", 0, 16, 12, 23, 0, 16, 12, 16, 12, 13], ["+", 31, 23, 0, 16, 12, 23, 0, 16, 12, 13]]
| 0
| 95
| 4
|
#include <stdio.h>
int main(void) {
int n, debt = 99999;
for (scanf("%d", &n); n--; debt = ((int)(debt * 1.05) / 1000 + 1) * 1000)
;
printf("%d\n", debt);
return 0;
}
|
#include <stdio.h>
int main(void) {
int n, debt = 100000;
for (scanf("%d", &n); n--; debt = ((int)(debt * 1.05 - 1) / 1000 + 1) * 1000)
;
printf("%d\n", debt);
return 0;
}
|
[["-", 0, 14, 8, 9, 0, 43, 49, 50, 51, 13], ["+", 0, 14, 8, 9, 0, 43, 49, 50, 51, 13], ["+", 31, 16, 31, 74, 51, 23, 0, 16, 17, 33], ["+", 31, 16, 31, 74, 51, 23, 0, 16, 12, 13]]
| 0
| 64
| 4
|
#include <stdio.h>
int main(void) {
int n, i, b, c, d, e, f;
b = 100;
d = 100000;
scanf("%d", &n);
for (i = 0; i < n; i++) {
c = b * 1.05;
e = d * 1.05;
if (c * 1000 != e) {
c = c + 1;
}
b = c;
d = e;
}
printf("%d\n", c * 1000);
return 0;
}
|
#include <stdio.h>
int main(void) {
int n, i, b, c, d, e, f;
b = 100;
d = 100000;
scanf("%d", &n);
for (i = 0; i < n; i++) {
c = b * 1.05;
e = d * 1.05;
if (c * 1000 != e) {
c = c + 1;
}
b = c;
d = c * 1000;
}
printf("%d\n", c * 1000);
return 0;
}
|
[["-", 0, 7, 8, 9, 0, 1, 0, 11, 12, 22], ["+", 8, 9, 0, 1, 0, 11, 12, 16, 31, 22], ["+", 8, 9, 0, 1, 0, 11, 12, 16, 17, 48], ["+", 8, 9, 0, 1, 0, 11, 12, 16, 12, 13]]
| 0
| 108
| 4
|
#include <stdio.h>
int main() {
int d = 100000;
int n, i;
scanf("%d", &n);
for (i = 0; i < n; i++) {
d *= 1.05;
}
if (d % 1000 != 0) {
d = d - d % 1000 + 1000;
}
printf("%d\n", d);
return 0;
}
|
#include <stdio.h>
int main() {
int d = 100000;
int n, i;
scanf("%d", &n);
for (i = 0; i < n; i++) {
d *= 1.05;
if (d % 1000 != 0) {
d = d - d % 1000 + 1000;
}
}
printf("%d\n", d);
return 0;
}
|
[["-", 0, 14, 8, 9, 0, 7, 8, 9, 0, 46], ["+", 0, 7, 8, 9, 0, 57, 64, 9, 0, 46]]
| 0
| 80
| 2
|
#include <stdio.h>
int main() {
int n, i;
unsigned long int debt_price;
scanf("%d", &n);
debt_price = 100000;
for (i = 0; i < n; i++) {
debt_price *= 1.05;
if (debt_price % 1000)
(debt_price / 1000 + 1) * 1000;
}
printf("%lu\n", debt_price);
return 0;
}
|
#include <stdio.h>
int main() {
int n, i;
unsigned long int debt_price;
scanf("%d", &n);
debt_price = 100000;
for (i = 0; i < n; i++) {
debt_price *= 1.05;
if (debt_price % 1000)
debt_price = (debt_price / 1000 + 1) * 1000;
}
printf("%lu\n", debt_price);
return 0;
}
|
[["+", 8, 9, 0, 57, 64, 1, 0, 11, 31, 22], ["+", 8, 9, 0, 57, 64, 1, 0, 11, 17, 32]]
| 0
| 80
| 2
|
#include <stdio.h>
int main(void) {
int n, i, debt = 100000;
scanf("%d", &n);
for (i = 0; i < n; i++) {
debt *= 1.05;
}
if (debt % 10000 != 0) {
debt = (debt / 10000 + 1) * 10000;
}
printf("%d\n", debt);
return 0;
}
|
#include <stdio.h>
int main(void) {
int n, i, debt = 100000;
scanf("%d", &n);
for (i = 0; i < n; i++) {
debt *= 1.05;
if (debt % 1000 != 0) {
debt = (debt / 1000 + 1) * 1000;
}
}
printf("%d\n", debt);
return 0;
}
|
[["-", 0, 14, 8, 9, 0, 7, 8, 9, 0, 46], ["-", 0, 57, 15, 23, 0, 16, 31, 16, 12, 13], ["+", 0, 57, 15, 23, 0, 16, 31, 16, 12, 13], ["-", 12, 16, 31, 23, 0, 16, 31, 16, 12, 13], ["+", 12, 16, 31, 23, 0, 16, 31, 16, 12, 13], ["-", 64, 9, 0, 1, 0, 11, 12, 16, 12, 13], ["+", 64, 9, 0, 1, 0, 11, 12, 16, 12, 13], ["+", 0, 7, 8, 9, 0, 57, 64, 9, 0, 46]]
| 0
| 82
| 8
|
#include <stdio.h>
main() {
int week;
int i;
int res = 100000;
int l;
scanf("%d", &week);
for (i = 0; i < week; i++) {
res += res * 0.05;
}
res += 9999;
l = res % 10000;
res -= l;
printf("%d\n", res);
return 0;
}
|
#include <stdio.h>
main() {
int week;
int i;
int res = 100000;
int l;
scanf("%d", &week);
for (i = 0; i < week; i++) {
res += res * 0.05;
res += 999;
l = res % 1000;
res -= l;
}
printf("%d\n", res);
return 0;
}
|
[["-", 0, 30, 0, 9, 0, 7, 8, 9, 0, 46], ["-", 0, 30, 0, 9, 0, 1, 0, 11, 12, 13], ["+", 0, 7, 8, 9, 0, 1, 0, 11, 12, 13], ["-", 0, 9, 0, 1, 0, 11, 12, 16, 12, 13], ["+", 8, 9, 0, 1, 0, 11, 12, 16, 12, 13], ["+", 0, 30, 0, 9, 0, 7, 8, 9, 0, 46]]
| 0
| 80
| 6
|
#include <stdio.h>
struct yami {
double kinri;
int fusai;
};
int main(void) {
int i, week;
struct yami a;
a.kinri = 0.05;
a.fusai = 100000;
scanf("%d", &week);
for (i = 0; i < week; i++) {
a.fusai *= (1 + a.kinri);
}
if (a.fusai % 1000 != 0) {
a.fusai /= 10000;
a.fusai += 1;
a.fusai *= 10000;
}
printf("%d\n", a.fusai);
return 0;
}
|
#include <stdio.h>
struct yami {
double kinri;
int fusai;
};
int main(void) {
int i, week;
struct yami a;
a.kinri = 0.05;
a.fusai = 100000;
scanf("%d", &week);
for (i = 0; i < week; i++) {
a.fusai *= (1 + a.kinri);
if (a.fusai % 1000 != 0) {
a.fusai /= 1000;
a.fusai += 1;
a.fusai *= 1000;
}
}
printf("%d\n", a.fusai);
return 0;
}
|
[["-", 0, 14, 8, 9, 0, 7, 8, 9, 0, 46], ["-", 0, 57, 64, 9, 0, 1, 0, 11, 12, 13], ["+", 0, 57, 64, 9, 0, 1, 0, 11, 12, 13], ["+", 0, 7, 8, 9, 0, 57, 64, 9, 0, 46]]
| 0
| 123
| 6
|
//↓template↓
#include "bits/stdc++.h"
using namespace std;
#define Would
#define you
#define all(n) n.begin(), n.end()
const long long INF = 1e18;
const long long MOD = 1e9 + 7;
const double pi = acos(-1);
const int SIZE = 1 << 17;
int dx[] = {1, 0, -1, 0}, dy[] = {0, 1, 0, -1}, alp[30];
long long fac[200005], finv[200005], inv[200005];
vector<long long> dij;
struct edge {
long long to, cost;
};
vector<vector<edge>> G;
long long mod_pow(long long a, long long b) {
long long res = 1, mul = a;
for (int i = 0; i < 31; ++i) {
if (b >> i & 1) {
res *= mul;
res %= MOD;
}
mul = (mul * mul) % MOD;
}
return res;
}
void addedge(int from, int to, int cost) {
G[from].push_back({to, cost});
G[to].push_back({from, cost});
}
//↑template↑
int main() {
long long n, ans = 100000;
cin >> n;
while (--n) {
ans = (ans + ans / 20 + 999) / 1000 * 1000;
}
cout << ans << endl;
}
|
//↓template↓
#include "bits/stdc++.h"
using namespace std;
#define Would
#define you
#define all(n) n.begin(), n.end()
const long long INF = 1e18;
const long long MOD = 1e9 + 7;
const double pi = acos(-1);
const int SIZE = 1 << 17;
int dx[] = {1, 0, -1, 0}, dy[] = {0, 1, 0, -1}, alp[30];
long long fac[200005], finv[200005], inv[200005];
vector<long long> dij;
struct edge {
long long to, cost;
};
vector<vector<edge>> G;
long long mod_pow(long long a, long long b) {
long long res = 1, mul = a;
for (int i = 0; i < 31; ++i) {
if (b >> i & 1) {
res *= mul;
res %= MOD;
}
mul = (mul * mul) % MOD;
}
return res;
}
void addedge(int from, int to, int cost) {
G[from].push_back({to, cost});
G[to].push_back({from, cost});
}
//↑template↑
int main() {
long long n, ans = 100000;
cin >> n;
while (n--) {
ans = (ans + ans / 20 + 999) / 1000 * 1000;
}
cout << ans << endl;
}
|
[["-", 8, 9, 0, 52, 15, 339, 51, 27, 17, 68], ["+", 8, 9, 0, 52, 15, 339, 51, 27, 17, 68]]
| 1
| 291
| 2
|
#include <iostream>
using namespace std;
int main() {
int n;
cin >> n;
int ans = 100000;
for (int i = 0; i < n; i++)
ans += ans * 5 / 100;
if (ans % 10000)
ans += (10000 - ans % 10000);
cout << ans << endl;
}
|
#include <iostream>
using namespace std;
int main() {
int n;
cin >> n;
int ans = 100000;
for (int i = 0; i < n; i++) {
ans += ans * 5 / 100;
if (ans % 1000)
ans += (1000 - ans % 1000);
}
cout << ans << endl;
}
|
[["+", 0, 14, 8, 9, 0, 7, 8, 9, 0, 45], ["-", 8, 9, 0, 57, 15, 339, 51, 16, 12, 13], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 12, 13], ["-", 64, 1, 0, 11, 12, 23, 0, 16, 31, 13], ["+", 64, 1, 0, 11, 12, 23, 0, 16, 31, 13], ["-", 0, 11, 12, 23, 0, 16, 12, 16, 12, 13], ["+", 0, 11, 12, 23, 0, 16, 12, 16, 12, 13], ["+", 0, 14, 8, 9, 0, 7, 8, 9, 0, 46]]
| 1
| 68
| 8
|
#include <iostream>
using namespace std;
int main(void) {
int money = 100000;
int n;
cin >> n;
for (int i = 0; i < n; i++) {
money = money + ((int)(money * 0.05) + 900) / 1000 * 1000;
}
cout << money << endl;
}
|
#include <iostream>
using namespace std;
int main(void) {
int money = 100000;
int n;
cin >> n;
for (int i = 0; i < n; i++) {
money = money + ((int)(money * 0.05) + 999) / 1000 * 1000;
}
cout << money << endl;
}
|
[["-", 12, 16, 31, 16, 31, 23, 0, 16, 12, 13], ["+", 12, 16, 31, 16, 31, 23, 0, 16, 12, 13]]
| 1
| 68
| 2
|
#include <iostream>
using namespace std;
// 1000未満切り上げ
int main() {
int weeks;
int debt = 100000;
cin >> weeks;
for (int i = 0; i < weeks; i++) {
debt * 1.05;
if (debt % 1000)
debt += (1000 - debt % 1000);
}
cout << debt << endl;
}
|
#include <iostream>
using namespace std;
// 1000未満切り上げ
int main() {
int weeks;
int debt = 100000;
cin >> weeks;
for (int i = 0; i < weeks; i++) {
debt *= 1.05;
if (debt % 1000)
debt += (1000 - debt % 1000);
}
cout << debt << endl;
}
|
[["-", 0, 7, 8, 9, 0, 1, 0, 16, 17, 48], ["+", 0, 7, 8, 9, 0, 1, 0, 11, 17, 108]]
| 1
| 67
| 2
|
#include <cmath>
#include <iostream>
using namespace std;
int main() {
int n, i;
double a = 100000;
cin >> n;
for (i = 0; i < n; i++) {
a *= 1.05;
ceil(a);
while ((int)a % 1000 != 0) {
a += 1;
}
}
cout << a << endl;
}
|
#include <cmath>
#include <iostream>
using namespace std;
int main() {
int n, i;
double a = 100000;
cin >> n;
for (i = 0; i < n; i++) {
a *= 1.05;
ceil(a);
while ((int)a % 1000 != 0) {
a += 1;
}
}
cout << (int)a << endl;
}
|
[["+", 0, 1, 0, 16, 31, 16, 12, 74, 0, 24], ["+", 0, 16, 31, 16, 12, 74, 39, 77, 39, 40], ["+", 0, 1, 0, 16, 31, 16, 12, 74, 0, 25]]
| 1
| 75
| 3
|
#include <iostream>
#include <math.h>
using namespace std;
int main() {
unsigned int week;
cin >> week;
float debt = 100; // in unit of 1000.
for (int i = 0; i < week; i++) {
debt *= 1.05;
debt = ceil(debt);
}
cout << debt * 1000 << endl;
return 0;
}
|
#include <iostream>
#include <math.h>
using namespace std;
int main() {
unsigned int week;
cin >> week;
float debt = 100; // in unit of 1000.
for (int i = 0; i < week; i++) {
debt *= 1.05;
debt = ceil(debt);
}
cout << (int)debt * 1000 << endl;
return 0;
}
|
[["+", 0, 16, 31, 16, 12, 16, 31, 74, 0, 24], ["+", 31, 16, 12, 16, 31, 74, 39, 77, 39, 40], ["+", 0, 16, 31, 16, 12, 16, 31, 74, 0, 25]]
| 1
| 66
| 3
|
#define _USE_MATH_DEFINES
#include <cmath>
#include <iostream>
using namespace std;
int main() {
unsigned int n;
cin >> n;
double a = 100000;
for (int i = 0; i < n; i++) {
a *= 1.05;
a /= 1000;
a = ceil(a);
a *= 1000;
}
cout << a << endl;
return 0;
}
|
#define _USE_MATH_DEFINES
#include <cmath>
#include <iostream>
using namespace std;
int main() {
unsigned int n;
cin >> n;
double a = 100000;
for (int i = 0; i < n; i++) {
a *= 1.05;
a /= 1000;
a = ceil(a);
a *= 1000;
}
cout << (int)a << endl;
return 0;
}
|
[["+", 0, 1, 0, 16, 31, 16, 12, 74, 0, 24], ["+", 0, 16, 31, 16, 12, 74, 39, 77, 39, 40], ["+", 0, 1, 0, 16, 31, 16, 12, 74, 0, 25]]
| 1
| 73
| 3
|
#include <algorithm>
#include <iostream>
#include <math.h>
#include <stdio.h>
#include <string>
using namespace std;
int main() {
int n;
double d = 100000;
cin >> n;
for (int i = 0; i < n; i++) {
d *= 1.05 / 1000;
if (d - floor(d) > 0.00001) {
d = ceil(d) * 1000;
} else
d *= 1000;
}
cout << d << endl;
return 0;
}
|
#include <algorithm>
#include <iostream>
#include <math.h>
#include <stdio.h>
#include <string>
using namespace std;
int main() {
int n;
double d = 100000;
cin >> n;
for (int i = 0; i < n; i++) {
d *= 1.05 / 1000;
if (d - floor(d) > 0.00001) {
d = ceil(d) * 1000;
} else
d *= 1000;
}
cout << (int)d << endl;
return 0;
}
|
[["+", 0, 1, 0, 16, 31, 16, 12, 74, 0, 24], ["+", 0, 16, 31, 16, 12, 74, 39, 77, 39, 40], ["+", 0, 1, 0, 16, 31, 16, 12, 74, 0, 25]]
| 1
| 90
| 3
|
#include <algorithm>
#include <functional>
#include <iomanip>
#include <ios>
#include <iostream>
#include <math.h>
#include <string>
#define YES "YES"
#define NO "NO"
#define space ' '
using namespace std;
void func();
int main(void) {
func();
return 0;
}
void func() {
int n, debt;
debt = 100000;
cin >> n;
while (n-- > 0) {
debt = debt + debt * 0.05;
if (debt % 1000 > 0)
debt += 1000 - debt % 1000;
cout << debt << endl;
}
}
|
#include <algorithm>
#include <functional>
#include <iomanip>
#include <ios>
#include <iostream>
#include <math.h>
#include <string>
#define YES "YES"
#define NO "NO"
#define space ' '
using namespace std;
void func();
int main(void) {
func();
return 0;
}
void func() {
int n, debt;
debt = 100000;
cin >> n;
while (n-- > 0) {
debt = debt + debt * 0.05;
if (debt % 1000 > 0)
debt += 1000 - debt % 1000;
}
cout << debt << endl;
}
|
[["+", 0, 14, 8, 9, 0, 52, 8, 9, 0, 46], ["-", 0, 14, 8, 9, 0, 52, 8, 9, 0, 46]]
| 1
| 104
| 2
|
#include <cstdio>
int main() {
int n;
int a = 100;
scanf("%d", &n);
for (int i = 0; i < n; i++) {
if (a % 100) {
a = a * 1.05 + 1;
} else {
a *= 1.05;
}
}
printf("%d000\n", a);
return 0;
}
|
#include <cstdio>
int main() {
int n;
int a = 100;
scanf("%d", &n);
for (int i = 0; i < n; i++) {
if (a % 20) {
a = a * 1.05 + 1;
} else {
a *= 1.05;
}
}
printf("%d000\n", a);
return 0;
}
|
[["-", 8, 9, 0, 57, 15, 339, 51, 16, 12, 13], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 12, 13]]
| 1
| 78
| 2
|
#include <iostream>
using namespace std;
#include <math.h>
int main() {
int n = 0;
double syakkin = 100000.0;
cin >> n;
for (int i = 0; i < n; i++) {
syakkin = syakkin * 1.05;
if (long(syakkin) % 1000 != 0) {
syakkin = syakkin - double(long(syakkin) % 1000) + 1000.0;
}
// cout << syakkin << endl;
}
cout << syakkin << endl;
return 0;
}
|
#include <iostream>
using namespace std;
#include <math.h>
int main() {
int n = 0;
double syakkin = 100000.0;
cin >> n;
for (int i = 0; i < n; i++) {
syakkin = syakkin * 1.05;
if (long(syakkin) % 1000 != 0) {
syakkin = syakkin - double(long(syakkin) % 1000) + 1000.0;
}
// cout << syakkin << endl;
}
cout << long(syakkin) << endl;
return 0;
}
|
[["+", 0, 1, 0, 16, 31, 16, 12, 2, 63, 22], ["+", 0, 16, 31, 16, 12, 2, 3, 4, 0, 24], ["+", 0, 16, 31, 16, 12, 2, 3, 4, 0, 25]]
| 1
| 89
| 3
|
#include <cstdio>
using namespace std;
long long roundup(long long *x) {
(*x) += 900;
(*x) /= 1000;
(*x) *= 1000;
}
long long addinterest(long long *x) {
(*x) *= 1.05;
roundup(x);
}
int main() {
long long debt = 100000;
int n;
scanf("%d", &n);
while (n--)
addinterest(&debt);
printf("%lld\n", debt);
return 0;
}
|
#include <cstdio>
using namespace std;
long long roundup(long long *x) {
(*x) += 999;
(*x) /= 1000;
(*x) *= 1000;
}
long long addinterest(long long *x) {
(*x) *= 1.05;
roundup(x);
}
int main() {
long long debt = 100000;
int n;
scanf("%d", &n);
while (n--)
addinterest(&debt);
printf("%lld\n", debt);
return 0;
}
|
[["-", 0, 14, 8, 9, 0, 1, 0, 11, 12, 13], ["+", 0, 14, 8, 9, 0, 1, 0, 11, 12, 13]]
| 1
| 110
| 2
|
#include <iostream>
using namespace std;
int main() {
int n, i, j;
double debt = 100000;
cin >> n;
for (i = 0; i < n; i++) {
debt = (double)debt * 1.05;
if ((int)debt / 1000 * 1000 != (int)debt) {
debt = (int)debt / 1000 * 1000 + 1000;
}
}
cout << debt << endl;
return 0;
}
|
#include <iostream>
using namespace std;
int main() {
int n, i, j;
int debt = 100000;
cin >> n;
for (i = 0; i < n; i++) {
debt = (double)debt * 1.05;
if ((int)debt / 1000 * 1000 != (int)debt) {
debt = (int)debt / 1000 * 1000 + 1000;
}
}
cout << debt << endl;
return 0;
}
|
[["-", 0, 30, 0, 14, 8, 9, 0, 43, 39, 40], ["+", 0, 30, 0, 14, 8, 9, 0, 43, 39, 40]]
| 1
| 92
| 2
|
#include <iostream>
#include <math.h>
using namespace std;
int main() {
int week, fraction;
cin >> week;
double debt = 100000;
double const rate = 1.05;
for (int i = 0; i < week; i++) {
debt = debt * rate;
fraction = (int)debt % 1000;
if (fraction > 0) {
debt = debt + 1000 - fraction;
}
}
cout << debt << endl;
return 0;
}
|
#include <iostream>
#include <math.h>
using namespace std;
int main() {
int week, fraction;
cin >> week;
double debt = 100000;
double const rate = 1.05;
for (int i = 0; i < week; i++) {
debt = debt * rate;
fraction = (int)debt % 1000;
if (fraction > 0) {
debt = debt + 1000 - fraction;
}
}
cout << (int)debt << endl;
return 0;
}
|
[["+", 0, 1, 0, 16, 31, 16, 12, 74, 0, 24], ["+", 0, 16, 31, 16, 12, 74, 39, 77, 39, 40], ["+", 0, 1, 0, 16, 31, 16, 12, 74, 0, 25]]
| 1
| 90
| 3
|
#include <iostream>
using namespace std;
int main() {
int n;
int ans = 1000000;
cin >> n;
for (int i = 0; i < n; i++) {
ans *= 1.05;
if ((ans % 1000) != 0)
ans = ans - ans % 1000 + 1000;
}
cout << ans << endl;
return 0;
}
|
#include <iostream>
using namespace std;
int main() {
int n;
int ans = 100000;
cin >> n;
for (int i = 0; i < n; i++) {
ans *= 1.05;
if ((ans % 1000) != 0)
ans = ans - ans % 1000 + 1000;
}
cout << ans << endl;
return 0;
}
|
[["-", 0, 14, 8, 9, 0, 43, 49, 50, 51, 13], ["+", 0, 14, 8, 9, 0, 43, 49, 50, 51, 13]]
| 1
| 73
| 2
|
#include <iostream>
using namespace std;
const double BORROWING_AMOUNT = 100000;
int main() {
int n;
cin >> n;
double value = BORROWING_AMOUNT;
for (int i = 1; i <= n; ++i) {
value += value * 0.05;
int mod = (int)value % 1000;
if (mod > 0) {
value += 1000 - mod;
}
}
cout << value << endl;
return 0;
}
|
#include <iostream>
using namespace std;
const double BORROWING_AMOUNT = 100000;
int main() {
int n;
cin >> n;
double value = BORROWING_AMOUNT;
for (int i = 1; i <= n; ++i) {
value += value * 0.05;
int mod = (int)value % 1000;
if (mod > 0) {
value += 1000 - mod;
}
}
cout << (int)value << endl;
return 0;
}
|
[["+", 0, 1, 0, 16, 31, 16, 12, 74, 0, 24], ["+", 0, 16, 31, 16, 12, 74, 39, 77, 39, 40], ["+", 0, 1, 0, 16, 31, 16, 12, 74, 0, 25]]
| 1
| 85
| 3
|
#include <iostream>
using namespace std;
int main() {
int n;
cin >> n;
int debt = 100000;
for (int i = 0; i < n; ++i) {
debt *= 1.05;
if (debt % 1000 > 0)
debt += 1000;
debt /= 1000, debt *= 1000;
cout << debt << endl;
}
return 0;
}
|
#include <iostream>
using namespace std;
int main() {
int n;
cin >> n;
int debt = 100000;
for (int i = 0; i < n; ++i) {
debt *= 1.05;
if (debt % 1000 > 0)
debt += 1000;
debt /= 1000, debt *= 1000;
}
cout << debt << endl;
return 0;
}
|
[["+", 0, 14, 8, 9, 0, 7, 8, 9, 0, 46], ["-", 0, 14, 8, 9, 0, 7, 8, 9, 0, 46]]
| 1
| 73
| 2
|
#include <iostream>
#include <math.h>
using namespace std;
int main() {
double v = 100000;
double r;
int n;
cin >> n;
for (int i = 0; i < n; i++) {
v += v * 0.05;
r = fmod(v, 1000.0);
if (r != 0) {
v += (1000 - r);
}
}
cout << v << endl;
return 0;
}
|
#include <iostream>
#include <math.h>
using namespace std;
int main() {
double v = 100000;
double r;
int n;
cin >> n;
for (int i = 0; i < n; i++) {
v += v * 0.05;
r = fmod(v, 1000.0);
if (r != 0) {
v += (1000 - r);
}
}
n = v;
cout << n << endl;
return 0;
}
|
[["+", 0, 14, 8, 9, 0, 1, 0, 11, 31, 22], ["+", 0, 14, 8, 9, 0, 1, 0, 11, 17, 32], ["+", 0, 14, 8, 9, 0, 1, 0, 11, 12, 22], ["+", 0, 30, 0, 14, 8, 9, 0, 1, 0, 35], ["-", 8, 9, 0, 1, 0, 16, 31, 16, 12, 22], ["+", 8, 9, 0, 1, 0, 16, 31, 16, 12, 22]]
| 1
| 85
| 6
|
#include <cmath>
#include <iostream>
using namespace std;
int main() {
double n;
cin >> n;
double ret = 100000;
for (int i = 0; i < n; i++) {
ret *= 1.05;
ret /= 1000;
ret = ceil(ret) * 1000;
}
cout << ret << endl;
return 0;
}
|
#include <cmath>
#include <iostream>
using namespace std;
int main() {
double n;
cin >> n;
double ret = 100000;
for (int i = 0; i < n; i++) {
ret *= 1.05;
ret /= 1000;
ret = ceil(ret) * 1000;
}
cout << (int)ret << endl;
return 0;
}
|
[["+", 0, 1, 0, 16, 31, 16, 12, 74, 0, 24], ["+", 0, 16, 31, 16, 12, 74, 39, 77, 39, 40], ["+", 0, 1, 0, 16, 31, 16, 12, 74, 0, 25]]
| 1
| 68
| 3
|
#include <algorithm>
#include <cstring>
#include <iostream>
using namespace std;
int main() {
int n;
cin >> n;
int price = 100000;
for (int i = 0; i < n; i++) {
price *= 1.05;
}
if (price % 1000 != 0)
price = price - (price % 1000) + 1000;
cout << price << endl;
}
|
#include <algorithm>
#include <cmath>
#include <iostream>
using namespace std;
int main() {
int n;
cin >> n;
int price = 100000;
for (int i = 0; i < n; i++) {
price *= 1.05;
if (price % 1000 != 0)
price = price - (price % 1000) + 1000;
}
cout << price << endl;
}
|
[["-", 36, 36, 36, 36, 0, 30, 0, 135, 136, 137], ["+", 36, 36, 36, 36, 0, 30, 0, 135, 136, 137], ["-", 0, 14, 8, 9, 0, 7, 8, 9, 0, 46], ["+", 0, 14, 8, 9, 0, 7, 8, 9, 0, 46]]
| 1
| 74
| 4
|
#include <cmath>
#include <iostream>
using namespace std;
int main() {
int n;
double m = 100;
cin >> n;
while (n--) {
m = ceil(m * 1.05);
}
cout << m * 1000 << endl;
return 0;
}
|
#include <cmath>
#include <iostream>
using namespace std;
int main() {
int n, m = 100;
cin >> n;
while (n--) {
m = ceil(m * 1.05);
}
cout << m * 1000 << endl;
return 0;
}
|
[["-", 0, 30, 0, 14, 8, 9, 0, 43, 0, 35], ["-", 0, 30, 0, 14, 8, 9, 0, 43, 39, 40], ["+", 0, 30, 0, 14, 8, 9, 0, 43, 0, 21]]
| 1
| 53
| 3
|
#include <iostream>
using namespace std;
int main() {
double money = 100000;
int n;
cin >> n;
for (int i = 1; i <= n; i++) {
//???????????????
money *= 1.05;
// 1000??????????????°?????????
double miman = money - ((int)(money * 0.001)) * 1000.0;
if (miman > 0) {
money = money - miman + 1000.0;
}
}
cout << money << endl;
return 0;
}
|
#include <iostream>
using namespace std;
int main() {
double money = 100000;
int n;
cin >> n;
for (int i = 1; i <= n; i++) {
//???????????????
money *= 1.05;
// 1000??????????????°?????????
double miman = money - ((int)(money * 0.001)) * 1000.0;
if (miman > 0) {
money = money - miman + 1000.0;
}
}
cout << (int)money << endl;
return 0;
}
|
[["+", 0, 1, 0, 16, 31, 16, 12, 74, 0, 24], ["+", 0, 16, 31, 16, 12, 74, 39, 77, 39, 40], ["+", 0, 1, 0, 16, 31, 16, 12, 74, 0, 25]]
| 1
| 89
| 3
|
#include <stdio.h>
int main() {
int i, n;
int sum = 100000;
scanf("%d", &n);
for (i = 0; i < n; i++) {
sum = sum * 1.05;
}
if (sum % 1000 != 0) {
sum = sum / 1000;
sum = (sum + 1) * 1000;
}
printf("%d\n", sum);
return 0;
}
|
#include <stdio.h>
int main() {
int i, n;
int sum = 100000;
scanf("%d", &n);
for (i = 0; i < n; i++) {
sum = sum * 1.05;
if (sum % 1000 != 0) {
sum = sum / 1000;
sum = (sum + 1) * 1000;
}
}
printf("%d\n", sum);
return 0;
}
|
[["-", 0, 14, 8, 9, 0, 7, 8, 9, 0, 46], ["+", 0, 7, 8, 9, 0, 57, 64, 9, 0, 46]]
| 1
| 88
| 2
|
#include <iostream>
using namespace std;
int main() {
int n;
cin >> n;
int debt = 100000;
for (int i = 0; i < n; i++) {
debt = (int)((debt * 1.05 + 900) / 1000) * 1000;
}
cout << debt << endl;
}
|
#include <iostream>
using namespace std;
int main() {
int n;
cin >> n;
int debt = 100000;
for (int i = 0; i < n; i++) {
debt = (int)((debt * 1.05 + 999) / 1000) * 1000;
}
cout << debt << endl;
}
|
[["-", 51, 23, 0, 16, 31, 23, 0, 16, 12, 13], ["+", 51, 23, 0, 16, 31, 23, 0, 16, 12, 13]]
| 1
| 65
| 2
|
#include <iostream>
using namespace std;
int round(double num);
int main() {
int n = 100;
int w;
cin >> w;
for (int i = 0; i < w; i++) {
n = round(n * 1.05);
}
cout << n << endl;
return 0;
}
int round(double n) {
int m = n;
if (n > m)
return m + 1;
if (n == m)
return m;
}
|
#include <iostream>
using namespace std;
int round(double num);
int main() {
int n = 100;
int w;
cin >> w;
for (int i = 0; i < w; i++) {
n = round(n * 1.05);
}
cout << n * 1000 << endl;
return 0;
}
int round(double n) {
int m = n;
if (n > m)
return m + 1;
if (n == m)
return m;
}
|
[["+", 0, 1, 0, 16, 31, 16, 12, 16, 17, 48], ["+", 0, 1, 0, 16, 31, 16, 12, 16, 12, 13]]
| 1
| 98
| 2
|
#include <iostream>
using namespace std;
int StartDebt = 100000;
int main() {
int n;
cin >> n;
for (int i = 0; i < n; i++) {
StartDebt *= 1.05;
}
if (StartDebt % 10000 != 0) {
StartDebt = 10000 * (StartDebt / 10000 + 1);
}
cout << StartDebt << endl;
return 0;
}
|
#include <iostream>
using namespace std;
int StartDebt = 100000;
int main() {
int n;
cin >> n;
for (int i = 0; i < n; i++) {
StartDebt *= 1.05;
if (StartDebt % 1000 != 0) {
StartDebt = 1000 * (StartDebt / 1000 + 1);
}
}
cout << StartDebt << endl;
return 0;
}
|
[["-", 0, 14, 8, 9, 0, 7, 8, 9, 0, 46], ["-", 0, 57, 15, 339, 51, 16, 31, 16, 12, 13], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 12, 13], ["-", 64, 9, 0, 1, 0, 11, 12, 16, 31, 13], ["+", 64, 9, 0, 1, 0, 11, 12, 16, 31, 13], ["-", 12, 16, 12, 23, 0, 16, 31, 16, 12, 13], ["+", 12, 16, 12, 23, 0, 16, 31, 16, 12, 13], ["+", 0, 7, 8, 9, 0, 57, 64, 9, 0, 46]]
| 1
| 75
| 8
|
#include <cmath>
#include <iostream>
using namespace std;
int RoundUp(int Integer, int Power) {
int Place = pow(10, Power);
return Place * ceil(Integer / Place);
}
int main() {
int Debt = 100000;
int n;
cin >> n;
for (int i = 0; i < n; i++) {
Debt = RoundUp(
1.05 * Debt,
3); //?????¬???????????????????????±????????§??????????????????????????????????????????
}
cout << Debt << endl;
return 0;
}
|
#include <cmath>
#include <iostream>
using namespace std;
int RoundUp(int Integer, int Power) {
double Place = pow(10, Power);
return Place * ceil(Integer / Place);
}
int main() {
int Debt = 100000;
int n;
cin >> n;
for (int i = 0; i < n; i++) {
Debt = RoundUp(
1.05 * Debt,
3); //?????¬???????????????????????±????????§??????????????????????????????????????????
}
cout << Debt << endl;
return 0;
}
|
[["-", 0, 30, 0, 14, 8, 9, 0, 43, 39, 40], ["+", 0, 30, 0, 14, 8, 9, 0, 43, 39, 40]]
| 1
| 94
| 2
|
//
// main.cpp
// CppTest
//
// Created by Ryu on 2017/02/08.
// Copyright ?? 2017??´ Ryu. All rights reserved.
//
#include <algorithm>
#include <cmath>
#include <cstdio>
#include <iostream>
using namespace std;
int main(int argc, const char *argv[]) {
// insert code here...
cin.tie(0);
ios::sync_with_stdio(false);
long n = 0;
cin >> n;
long rest = 100000;
for (int i = 0; i < n; i++) {
rest *= 1.05;
}
if (rest % 1000 != 0) {
rest = rest + 1000 - rest % 1000;
}
printf("%ld", rest);
return 0;
}
|
//
// main.cpp
// CppTest
//
// Created by Ryu on 2017/02/08.
// Copyright ?? 2017??´ Ryu. All rights reserved.
//
#include <algorithm>
#include <cmath>
#include <cstdio>
#include <iostream>
using namespace std;
int main(int argc, const char *argv[]) {
// insert code here...
cin.tie(0);
ios::sync_with_stdio(false);
long n = 0;
cin >> n;
long rest = 100000;
for (int i = 0; i < n; i++) {
rest *= 1.05;
if (rest % 1000 != 0) {
rest = rest + 1000 - rest % 1000;
}
}
printf("%ld\n", rest);
return 0;
}
|
[["-", 0, 14, 8, 9, 0, 7, 8, 9, 0, 46], ["+", 0, 14, 8, 9, 0, 7, 8, 9, 0, 46], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44]]
| 1
| 115
| 3
|
#include <bits/stdc++.h>
using namespace std;
int main() {
ios ::sync_with_stdio(false);
int n;
cin >> n;
int t = 100000;
while (n--) {
t = t + t / 20;
int r = t % 1000;
t = t - r + (r >= 500 ? 1000 : 0);
}
cout << t << '\n';
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
ios ::sync_with_stdio(false);
int n;
cin >> n;
int t = 100000;
while (n--) {
t = t + t / 20;
int r = t % 1000;
t = t - r + (r > 0 ? 1000 : 0);
}
cout << t << '\n';
return 0;
}
|
[["-", 12, 16, 12, 23, 0, 41, 15, 16, 17, 20], ["-", 12, 16, 12, 23, 0, 41, 15, 16, 12, 13], ["+", 12, 16, 12, 23, 0, 41, 15, 16, 17, 47], ["+", 12, 16, 12, 23, 0, 41, 15, 16, 12, 13]]
| 1
| 80
| 4
|
#include <iostream>
int main(void) {
int n;
std::cin >> n;
int cost = 100000;
double cost_temp;
for (int i = 0; i < 5; i++) {
cost_temp = cost * 1.05;
cost = cost_temp;
if (cost % 1000 != 0) {
cost += 1000;
}
cost = (cost / 1000) * 1000;
}
std::cout << cost << std::endl;
return 0;
}
|
#include <iostream>
int main(void) {
int n;
std::cin >> n;
int cost = 100000;
double cost_temp;
for (int i = 0; i < n; i++) {
cost_temp = cost * 1.05;
cost = cost_temp;
if (cost % 1000 != 0) {
cost += 1000;
}
cost = (cost / 1000) * 1000;
}
std::cout << cost << std::endl;
return 0;
}
|
[["-", 0, 14, 8, 9, 0, 7, 15, 16, 12, 13], ["+", 0, 14, 8, 9, 0, 7, 15, 16, 12, 22]]
| 1
| 89
| 2
|
#include <cstdio>
#include <cstdlib>
int main() {
int n;
scanf("%d", &n);
int ans = 100000;
for (int i = 0; i < n; i++) {
ans += 100000 * 0.05;
if (ans % 1000 > 0)
ans = ans - (ans % 1000) + 1000;
}
printf("%d\n", ans);
return 0;
}
|
#include <cstdio>
#include <cstdlib>
int main() {
int n;
scanf("%d", &n);
int ans = 100000;
for (int i = 0; i < n; i++) {
ans += (double)ans * 0.05;
if (ans % 1000 > 0)
ans = ans - (ans % 1000) + 1000;
}
printf("%d\n", ans);
return 0;
}
|
[["-", 8, 9, 0, 1, 0, 11, 12, 16, 31, 13], ["+", 0, 1, 0, 11, 12, 16, 31, 74, 0, 24], ["+", 0, 11, 12, 16, 31, 74, 39, 77, 39, 40], ["+", 0, 1, 0, 11, 12, 16, 31, 74, 0, 25], ["+", 0, 1, 0, 11, 12, 16, 31, 74, 51, 22]]
| 1
| 83
| 5
|
#include <cmath>
#include <iostream>
using namespace std;
int main() {
int remaind = 10;
int n;
cin >> n;
for (int i = 0; i < n; i++) {
remaind = (int)ceil(remaind * 1.05);
}
cout << remaind * 10000 << endl;
return 0;
}
|
#include <cmath>
#include <iostream>
using namespace std;
int main() {
int remaind = 100;
int n;
cin >> n;
for (int i = 0; i < n; i++) {
remaind = (int)ceil(remaind * 1.05);
}
cout << remaind * 1000 << endl;
return 0;
}
|
[["-", 0, 14, 8, 9, 0, 43, 49, 50, 51, 13], ["+", 0, 14, 8, 9, 0, 43, 49, 50, 51, 13], ["-", 0, 1, 0, 16, 31, 16, 12, 16, 12, 13], ["+", 0, 1, 0, 16, 31, 16, 12, 16, 12, 13]]
| 1
| 65
| 4
|
#include <iostream>
using namespace std;
int main() {
int a = 100000, b = 0, t = 0;
cin >> t;
// if(t==0)cout<<a<<endl;
// else if(t<=100){
for (int k = 1; k <= t; k++) {
b = a * 1.05;
b = (b + 900) / 1000 * 1000;
a = b;
}
cout << a << endl;
//}
}
|
#include <iostream>
using namespace std;
int main() {
int a = 100000, b = 0, t;
cin >> t;
for (int k = 0; k < t; k++) {
b = a * 1.05;
b = (b + 999) / 1000 * 1000;
a = b;
}
cout << a << endl;
}
|
[["-", 0, 14, 8, 9, 0, 43, 49, 50, 0, 32], ["-", 0, 14, 8, 9, 0, 43, 49, 50, 51, 13], ["-", 8, 9, 0, 7, 10, 43, 49, 50, 51, 13], ["+", 8, 9, 0, 7, 10, 43, 49, 50, 51, 13], ["-", 0, 14, 8, 9, 0, 7, 15, 16, 17, 19], ["+", 0, 14, 8, 9, 0, 7, 15, 16, 17, 18], ["-", 12, 16, 31, 16, 31, 23, 0, 16, 12, 13], ["+", 12, 16, 31, 16, 31, 23, 0, 16, 12, 13]]
| 1
| 76
| 8
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.