N,K=map(int,input().split()) P=998244353 def C(x,y): a=1 for i in range(y):a=(a*(x-i)*pow(i+1,-1,P))%P return a a=C(2*N+4,K) b=[C(N+2,K//2),0][K%2] c=max([C(N+2,K//2),[0,C(N+1,K//2)*2][N%2]][K%2],0) d=b e=max([[C(N//2+1,K//4),[0,C((N+1)//2,K//4)][N%2]][(K%4)//2],0][K%2],0) i=pow(2,-1,P) print((e+(b-e)*i+(c-e)*i+(d-e)*i+(a-b-c-d+e*2)*i*i)%P)