MOD = 998244353 N, M = map(int, input().split()) if N > M: N, M = M, N print(pow(2, M-1, MOD)*pow(2, (N-1)*M, MOD)%MOD)