⌨️

[AtCoder]ABC-369|A - 369

2024/09/17に公開

設問ページ

提出結果

def getIntMap():
    return map(int, input().split())


def main():
    A, B = getIntMap()

    print(1 if A == B else 3 if abs(A - B) % 2 == 0 else 2)


if __name__ == "__main__":
    main()

Discussion