Skip to content

Instantly share code, notes, and snippets.

@whatalnk
Created December 10, 2017 02:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save whatalnk/889167bf675579efe1c71b9df5590ba6 to your computer and use it in GitHub Desktop.
Save whatalnk/889167bf675579efe1c71b9df5590ba6 to your computer and use it in GitHub Desktop.
AtCoder ABC #076
n = int(input())
k = int(input())
number = 1
for i in range(n):
number = min(number * 2, number + k)
print(number)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment