MOD = 998244353 n,k = map(int, input().split()) div = pow(6, MOD-2, MOD) if n == 1: print(div) else: div *= div div %= MOD print(div)