Bob is decorating his kitchen, more precisely, the floor. He has found a prime candidate for the tiles he will use. They come in a simple form factor — a square tile that is diagonally split into white and black part as depicted in the figure below. [Image] 

The dimension of this tile is perfect for this kitchen, as he will need exactly $w \times h$ tiles without any scraps. That is, the width of the kitchen is $w$ tiles, and the height is $h$ tiles. As each tile can be rotated in one of four ways, he still needs to decide on how exactly he will tile the floor. There is a single aesthetic criterion that he wants to fulfil: two adjacent tiles must not share a colour on the edge — i.e. one of the tiles must have a white colour on the shared border, and the second one must be black. [Image] The picture on the left shows one valid tiling of a $3 \times 2$ kitchen. The picture on the right shows an invalid arrangement, as the bottom two tiles touch with their white parts. 

Find the number of possible tilings. As this number may be large, output its remainder when divided by $998244353$ (a prime number). 


-----Input-----

The only line contains two space separated integers $w$, $h$ ($1 \leq w,h \leq 1\,000$) — the width and height of the kitchen, measured in tiles.


-----Output-----

Output a single integer $n$ — the remainder of the number of tilings when divided by $998244353$.


-----Examples-----
Input
2 2

Output
16

Input
2 4

Output
64

Difficulty: interview

Starter code:

Solutions:
n, m = list(map(int, input().split()))
print(pow(2, n + m, 998244353))



w,h = list(map(int, input().split()))

def powermod(x, y, mod):
    if y == 0:
        return 1
    return (powermod((x * x) % mod, y // 2, mod) * (x if y % 2 else 1)) % mod

print(powermod(2, w + h, 998244353))


M = 998244353
w,h = list(map(int,input().split()))
print(pow(2,w+h,M))


n, m = map(int, input().split())
print(pow(2, n + m, 998244353))

n,m = map(int, input().split())
print(2**(n+m) % 998244353)

import sys

w,h = list(map(int, sys.stdin.readline().strip().split()))

p = 998244353
b = w + h
a = 2
ans = 1
while b > 0:
    if b % 2 == 1:
        b = b - 1
        ans = (ans * a) % p
    else:
        b = b // 2
        a = (a * a) % p
print(ans)

mod = 998244353

W, H = map(int, input().split())
print(pow(2, H+W, mod))

w, h = list(map(int, input().split()))

print(pow(2, w+h, 998244353))


h,w=list(map(int,input().split()))
print(pow(2,h+w,998244353))


print(pow(2,sum(map(int,input().split())),998244353))


x,y=map(int,input().split())
print (2**(x+y)%998244353)

a, b = list(map(int, input().split()))
print((2 ** (a + b)) % 998244353)


a, b = map(int, input().split())
print(2**(a+b) % 998244353)

k,m=map(int, input().split())
print(2**(k+m)%998244353)

k = sum(map(int, input().split()))
print(pow(2, k, 998244353))

import sys
input = sys.stdin.readline

mod = 998244353

w,h=list(map(int,input().split()))

print(4*pow(2,(w-1)+(h-1),mod)%mod)


h, w = map(int,input().split())
mod = 998244353
ans = pow(2, h + w, mod)
print(ans%mod)

w,h=list(map(int,input().split()))
print(pow(2,w+h,998244353))


w,h=map(int,input().split())
p=998244353
k=1
for i in range(w+h):
    k=(2*k)%p
print(k)

print(2**(sum(list(map(int,input().split()))))%998244353)

n, m = list(map(int, input().split()))
print(pow(2, m + n, 998244353))


h, w = [int(ele) for ele in input().split(" ")]
MODULO = 998244353

print(2**(h+w) % MODULO)

arr = input().split(' ')
w, h = int(arr[0]), int(arr[1])

MOD = 998244353

print(pow(2, w+h, MOD))


w, h = list(map(int, input().split()))
print(pow(2, w+h, 998244353))