x, y = list(map(float, input().split())) print("{0} {1}".format(round(x, 9), round(1-y, 9)))