print(1 if int(input()) % 4 != 2 else -1)