MOD = 998244353 m, x, y = map(int, input().split()) n = abs(y - x) - 1 if x == 1 or x == m: n += 1 if y == 1 or y == m: n += 1 if n == 0: print(0) else: a, b, c = 1, 1, 1 for i in range(n - 2): a, b, c = b, c, a + c a %= MOD b %= MOD c %= MOD print(b)