Problem2215--abc200b - 200th ABC-200

2215: abc200b - 200th ABC-200

[Creator : ]
Time Limit : 1.000 sec  Memory Limit : 128 MB

Description

Time Limit: 2 sec / Memory Limit: 1024 MB

Score : 200200 points

Problem Statement

You are given an integer NN.
Do the following operation KK times on it and print the resulting integer.
  • If NN is a multiple of 200200, divide it by 200200.
  • Otherwise, see NN as a string and append 200200 to the end of it.
    • For example, 77 would become 72007200 and 12341234 would become 12342001234200.

Constraints

  • All values in input are integers.
  • 1 \le N \le 10^51N100000
  • 1 \le K \le 201K20

Input

Input is given from Standard Input in the following format:
NNKK

Output

Print the answer as an integer.

Sample Input Copy

2021 4

Sample Output Copy

50531

HINT

Applying the operation on N=2021N=2021 results in NN becoming 2021 \rightarrow 2021200 \rightarrow 10106 \rightarrow 10106200 \rightarrow 5053120212021200101061010620050531.

Source/Category