文件目录

#include <bits/stdc++.h>
using namespace std;
int m, n;
long long qp[50][50] = {};
int main()
{
    cin >> m >> n;
    // 处理边界
    for (int i = 1; i <= m; i++)
    {
        qp[i][1] = 1;
    }
    for (int i = 1; i <= n; i++)
    {
        qp[1][i] = 1;
    }
    for (int i = 2; i <= m; i++)
    {
        for (int j = 2; j <= n; j++)
        {
            qp[i][j] = qp[i - 1][j] + qp[i][j - 1];
        }
    }
    cout << qp[m][n];
    return 0;
}