#include <bits/stdc++.h>
using namespace std;
int a[1100], n, k, sum, r;
map<int, int> mp;
bool b[110000];
void tub() {
  for (int i = 2; i <= n; i++)
    if (!b[i]) {
      a[r] = i, r++, mp[i]++;
      for (int j = i * i; j <= n; j += i) b[j] = true;
    }
}
int main() {
  cin >> n >> k;
  tub();
  for (int i = 1; a[i] <= n; i++) {
    int d = a[i - 1] + a[i] + 1;
    if (mp[d] != 0) sum++;
  }
  if (sum >= k)
    cout << "YES";
  else
    cout << "NO";
  return 0;
}
