S = list(map(int,list(input()))) P = 998244353 dp = [0] * len(S) dp[0] = S[0] now = 1 for i in range(1,len(S)): now = now * 2 % P dp[i] = 11 * dp[i-1] + now * S[i] dp[i] %= P print(dp[-1])