import java.util.*;
public class Main {
public static void main(String[] args) {
Scanner scan = new Scanner(System.in);
String mn = scan.nextLine();
int m = Integer.valueOf(mn.split(" ")[0].trim()); // 苹果数目
int n = Integer.valueOf(mn.split(" ")[1].trim()); // 盘子数目
int[][] dp = new int[n + 1][m + 1];
for (int i = 0; i <= n; i++) {
for (int j = 0; j <= m; j++) {
dp[i][j] = 1;
}
}
for (int i = 2; i <= n; i++) {
for (int j = 2; j <= m; j++) {
if (j < i) {
dp[i][j] = dp[i - 1][j];
continue;
}
dp[i][j] = dp[i - 1][j] + dp[i][j - i];
}
}
System.out.println(dp[n][m]);
}
}