#include <bits/stdc++.h>
using namespace std;
vector<int> v;
void SieveOfEratosthenes(int n) {
  bool prime[100001];
  n = 2 * n;
  memset(prime, true, sizeof(prime));
  int i, j;
  for (i = 2; i * i <= n; i++) {
    if (prime[i] == true) {
      for (j = i * i; j <= n; j += i) {
        prime[j] = false;
      }
    }
  }
  for (i = 2; i <= n; i++) {
    if (prime[i]) v.push_back(i);
  }
}
bool isprime(int n) {
  int i;
  if (n == 1) return false;
  for (i = 2; i * i <= n; i++) {
    if (n % i == 0) {
      return false;
      break;
    }
  }
  return true;
}
int main() {
  int n, k;
  cin >> n >> k;
  SieveOfEratosthenes(n);
  int i = 0, lol = 0;
  while (1) {
    int sum = v[i] + v[i + 1] + 1;
    i++;
    if (sum <= n) {
      if (isprime(sum)) {
        lol++;
      }
    } else
      break;
  }
  if (lol < k)
    cout << "NO" << endl;
  else
    cout << "YES" << endl;
  return 0;
}
