n,m = list(map(int,input().split()))  # n为横向的格子数,m为竖向的格子数
def f(x,y):
    if x == 0 or y == 0:
        return 1  # 路径只有一条
    else:
        return (f(x-1,y) + f(x,y-1))

print(f(n,m))