#include<iostream>
#include<vector>
using namespace std;
int main(){
int m = 0;
int n = 0;
while(cin >> n >> m){
vector<vector<int>>res(n+1,vector<int>(m+1,0));
for(int i = 0; i <= n; i++){
for(int j = 0; j <= m; j++){
if(i == 0 && j == 0){
res[i][j] = 1;
continue;
}
if(i == 0){
res[i][j] = 1;//初始化列和行
}else if(j == 0){
res[i][j] = 1;
}else{
res[i][j] = res[i][j-1] + res[i-1][j];
}
}
}
cout << res[n][m];
}
return 0;
}
03-26
244
12-20
493
07-30
231