XP, YP = map(int, input().split()) print(int((XP * XP + YP * YP) ** 0.5 + 1))