Go: package main

import "fmt"

func roundUp100(dept float64) float64 {
	iDept := int(dept)
	if iDept-(iDept/1000*1000) != 0 {
		iDept = ((iDept / 1000) + 1) * 1000
	}
	return float64(iDept)
}

func main() {
	var week int
	fmt.Scan(&week)

	dept := 100000.0
	for i := 0; i < week; i++ {

		dept *= 1.05
		dept = roundUp100(dept)
	}

	fmt.Println(dept)
}

//問題文が理解できていない感

C++: #include<cstdio>
int main(){
    int n;
    int sum=100000;
    scanf("%d",&n);
    for(int i=0;i<n;i++){
        sum+=sum*0.05;
        if(sum%1000) sum=(sum/1000+1)*1000;
    }
    printf("%d\n",sum);
}

C++: #include<stdio.h>

int main(){
  float money = 100.0f;
  const float RATE = 0.05f;
  int week;

  scanf("%d",&week);
  for(int i = 0;i < week;i++){
    money += money*RATE;
    if(money*1000.0f - (int)money*1000 > 0){
      money = (int)money + 1.0f;
    }
  }

  printf("%d\n",(int)money*1000);
  
return 0;
}

C++: #include <stdio.h>
int main(){
 int n,i;
 double debt=10000;
 scanf("%d",&n);
 while(n--){
     debt += debt*0.05;
     for(i=10;i<1000;i*=10){
         if(n%i!=0){
             debt += 1000;
             break;
         }
     }
 }
 printf("%lf\n",debt);
 return 0;
}

C++: #include <iostream>
#include <cstdio>
#include <cmath>
#include <vector>
#include <deque>
#include <list>
#include <string>
#include <stack>
#include <queue>
#include <set>
#include <map>
#include <algorithm>

using namespace std;

int n;

int main() {
	cin >> n;

	int money = 100000;
	for (int i = 0; i < n; i++) {
		money *= 1.05;

		int simo = money % 1000;
		if (simo != 0) money += 1000 - simo;
	}

	cout << money << endl;

	return 0;
}

/*@@@@@@@@@@@@@@@@@@@@@@@@@*/
/*@                       @*/
/*@ debug output erased ? @*/
/*@                       @*/
/*@@@@@@@@@@@@@@@@@@@@@@@@@*/

C++: #include<iostream>
using namespace std;int main(){int n,m=1e5;for(cin>>n;n>0;n--)m=(m*105/100+999)/1000*1000;cout<<m<<endl;return 0;}

C++: #include<iostream>
#include<stdio.h>
#include<algorithm>
#include<math.h>
#include<string.h>
using namespace std;
int main()
{
	int n,s=100000,a,b;
	cin>>n;
	for(int i=0;i<n;i++)
	{
		s*=1.05;
		if(s%1000>=1)
		{
			a=1000-s%1000;
			s+=a;
		}
	}
	cout<<s;
	return 0;
}

C++: #include<iostream>
using namespace std;

int main(){
	double money = 100000;
	int n;
	cin >> n;
	for( int i=0; i<n; i++ ){
		money = (double)money * 1.05;
		int up = money / 1000;
		if( (int)(money - up) > 0 )
			money = (up+1)*1000;
		else
			money = up * 1000;
	}
	int m = (int)money;
	cout << m << endl;
	return 0;
}

C++: #include <iostream>

using namespace std;

int main()
{
	int n;
	cin >> n;

	int ans = 100000;
	while(n--){
		ans*=1.05;
		if(ans%1000)
			ans=(ans/1000+1) * 1000;
	}
	cout << ans << endl;
	return 0;
}

C++: #include <stdio.h>

int main(){
	int i,n,debt = 100000;
	scanf("%d",&n);
	for(i = 0;i < n;i++){
		debt = (((int)(debt * 1.05) - 1) / 1000 + 1) * 1000;
	}
	printf("%d\n",debt);
}

C++: #include<iostream>
using namespace std;
int main(){
	float a,n,i,b,j,ans=0;
	a=100000;
	cin>>n;
	for(i=1;i<=n;i++){
		a=a*1.05;
	}
	for(i=1;1000<=a;i++){
		a=a-1000;
	}
	ans=i*1000;
	cout<<ans<<endl;
	return 0;
}

C++: #include <iostream>
#include <string>
using namespace std;

int n;

int main(){
	cin >> n;
	int k=100000;
	for(int i=0;i<n;i++){
		k*=1.05;
		if(k%1000 != 0){
			k-=k%1000;
			k+=1000;
		}
	}
	cout << (int)k <<endl;
	return 0;
}

C++: #include <iostream>
#include <vector>
#include <math.h>
#include <string>
#include <windows.h>

int main(void);
int kiriage(int num);


int main(){
	int n;					//n週
	int debut = 100000;		//借金
	std::cin >> n;

	for (int i = 0; i < n; i++)
	{
		debut *= 1.05;
		std::string str_debut = std::to_string(debut);
		if ((str_debut[str_debut.length() - 1] == '0') &&
			(str_debut[str_debut.length() - 2] == '0') &&
			(str_debut[str_debut.length() - 3] == '0')
			){
			;
		}
		else{
			debut = kiriage(debut);
		}
	}

	std::cout << debut << std::endl;

	//while (1);
	return 0;
}

//1000円未満を切り上げる関数
int kiriage(int num){
	num = num / 1000 * 1000 + 1000;
	
	return num;
}

C++: #include <iostream>
#include <cmath>

using namespace std;

int main() {
    int n, debt = 100000;

    cin >> n;

    for(int i = 0;i < n;i++){
        debt *= 1.05;
        if(debt % 1000 != 0){
            debt += 1000;
        }
         debt -= (debt % 1000);
    }

    cout << debt << endl; 

    return 0;
}

C++: #include<stdio.h>

int main(void){
  unsigned int start=100000;
  int i,j,k,n;
  scanf("%d",&n);
  for(i=0;i<n;i++){
    start/=100;
    start*=105;
    start/=1000;
    start+=1;
    start*=1000;
  }
  printf("%d\n",start);
  return 0;
}

C++: #include <iostream>
#include <cstdio>
#include <vector>
#include <list>
#include <algorithm>
#include <cmath>
#include <stack>
#include <set>
using namespace std;

#define REP(i,n) for(int (i)=0; (i)<(n); (i)++)
#define FOR(i,a,b) for(int (i)=(a); (i)<(b); (i)++)
#define PUSH(n,v) for(int i=0; i<(n); i++) {int j; cin >> j; v.push_back(j);}
#define ALL(v) v.begin(), v.end()

long money = 100000;

void oneweekafter() {
    money *= 1.05;
    money = ceil(money / 1000.) * 1000;
}

int main() {
    int n;
    cin >> n;
    REP(i,n) {
        oneweekafter();
    }
    cout << money << endl;
    return 0;
}

C++: #include <bits/stdc++.h>
//#include <iostream>
//#include <Windows.h>
using namespace std;

int main(){
int n;
double a=100;
cin>>n;
while(n--){
	a=a*5/100;
        a=ceil(a);
}
cout<<a*1000;
return 0;
}

C++: #include <iostream>
#include <math.h>
using namespace std;
int main(void){
   int a;
   float b = 100000.0f;
   std::cin >> a;
   if(a < 100 && a > 0){
       for(int i = 0; i < a; i++){
           b *= 1.05f;
           b /= 1000;
           double c = ceil(b);
           b = c * 1000;
       }
       std::cout << b << std::endl;
   }
}

C++: #include <iostream>

using namespace std;

int main() {
  int n;
  cin >> n;
  int debt = 100000;
  for (int i = 0; i < n; i++) {
    debt *= 1.05;
    debt = (debt + 999) / 1000 * 1000;
  }
  cout << debt << endl;
  return 0;
}

C++: #include<bits/stdc++.h>
using namespace std;
int main()
{
	double a;
	cin>>a;
	int ans=100000;
	for(int b=0;b<a;b++)
	{
		double rev=0;
	   ans=ans*1.05;
	   rev=ans%1000;
	   ans=ans-rev;
	   ans=ans+1000;
		}
		printf("%.15000000000lf\n",ans);
	}

C++: #include<stdio.h>
#include<math.h>


int main()
{
	int debt = 100000;
	int n, i;
	scanf("%d", &n);
	for (i = 0; i < n; i++)
	{
		debt = debt*1.05;
		if (debt % 1000 !=0)debt = debt / 1000 *1000 + 1000;
	}
	printf("%d\n", debt);
	return 0;
}

C++: #include <stdio.h>

int main()
{
	int n,zan = 100000;

	scanf("%d",&n);
	for(int i = 0; i < n; i++){
		zan += zan * 0.05;
		if(zan%1000 > 0){
			zan /= 1000;
			zan++;
			zan *= 1000;
		}
	}
	printf("%d\n",zan);

	return 0;
}

C++: #include <bits/stdc++.h>
using namespace std;
typedef long long LL;

int main(){
	int m=100000,n;
	cin>>n;
	for(int i=0;i<n;i++){
		m=m/20*21;
		m+=(1000-(m-1)%1000)-1;
	}
	cout<<m<<endl;
	return 0;
}

C++: #include <iostream>
#include <cmath>

int main(){
    int weeks, debt = 100000;
    std::cin >> weeks;
    for(int i=0; i<weeks; i++){
        debt *= 1.05;
        debt = ceil(debt / 1000.0) * 1000;
        std::cout << debt << std::endl;
    }
	return 0;
}

C++: #include <iostream>

using namespace std;

int interest(int);

int main(void){
	int loan=100000,week;

	cin >> week;
	for(int i=0;i<week;i++)
		loan+=interest(loan);

	cout << loan << endl;

	return 0;
}

int interest(int loan){
	float tmp=loan*0.05;

	if(tmp>(int)tmp/1000*1000)
		tmp=((int)tmp/1000+1)*1000;

	return (int)tmp;
}

C++: #include<iostream>
using namespace std;

int main()
{
	int money=100000;
	int n,tmp;
	cin>>n;
	for(int i=0;i<n;i++){
		money*=1.05;
		tmp=money%1000;
		if(tmp!=0){
			money-=tmp;
			money+=1000;
		}
	}
	cout<<money<<endl;
	return 0;
}

C++: #include <iostream>

int main(){
	int n,debt=100000;
	std::cin>>n;
	for(int i=0;i<n;i++){
		debt*=1.05;
		debt=debt%1000 ? debt/1000*1000+1000 : debt;
	}
	std::cout<<debt<<'\n';
	return 0;
}