#include <bits/stdc++.h>
using namespace std;
bool prime(int n) {
  int k = 2;
  while (n != k) {
    if (n % k == 0)
      return false;
    else {
      k++;
    }
  }
  return true;
}
int main() {
  int n, k, s = 0, t;
  vector<int> vec;
  cin >> n >> k;
  for (int i = 2; i <= n; i++) {
    if (prime(i)) vec.push_back(i);
  }
  for (int i = 0; i < vec.size() - 1; i++) {
    t = vec.at(i) + vec.at(i + 1) + 1;
    if (prime(t) && t <= n) s++;
  }
  if (s >= k)
    cout << "YES";
  else
    cout << "NO";
  return 0;
}
