Remainder#953

Remainder (Editorial)

Let's read string that's of length then the answer is

s=input()
print(int(s[2])%int(s[0]))