N, K = map(int, input().split()) A = list(map(int, input().split())) p = 998244343 ans = sum(A)%p ans *= pow(2, K, p) print(ans%p)