while line = gets
  value = line.chomp
  week = value.to_i
  money = 100000
  week.times do |i|
    money += (money/100*5)
    uptovalue = money % 1000
    if uptovalue != 0
      money -= uptovalue
      money += 1000
    end
  end
  print money.to_s + "\n"
end

