package no2xxx; import java.io.PrintWriter; import java.util.*; public class No2846_2 { static Scanner in; static PrintWriter out; static String INPUT = ""; static void solve() { int K = ni(), n = ni(); final int D = 55440; long[] dp = new long[D+1]; dp[0] = 1; for(int i = 0;i < K;i++){ long[] ndp = new long[D+1]; for(int k = 1;k <= n;k++){ if(k == 13 || k == 17 || k == 19 || k == 23)continue; int p = D/k; for(int j = 0;j+p <= D;j++) { ndp[j + p] += dp[j]; } } dp = ndp; } long ans = dp[D] + (K == 13 || K == 17 || K == 19 || K == 23 ? 1 : 0); out.println(ans); } public static void main(String[] args) throws Exception { in = INPUT.isEmpty() ? new Scanner(System.in) : new Scanner(INPUT); out = new PrintWriter(System.out); solve(); out.flush(); } static int ni() { return Integer.parseInt(in.next()); } static long nl() { return Long.parseLong(in.next()); } static double nd() { return Double.parseDouble(in.next()); } static void tr(Object... o) { if(INPUT.length() != 0)System.out.println(Arrays.deepToString(o)); } }