#include <bits/stdc++.h>
using namespace std;
void play() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
}
int main() {
  play();
  int a, b, arr[10000];
  cin >> a >> b;
  vector<int> v(a);
  vector<int> m(a);
  for (int i = 0; i < a; i++) {
    cin >> v[i];
    m[i] = v[i];
  }
  sort(v.begin(), v.end());
  v.resize(unique(v.begin(), v.end()) - v.begin());
  int c = v.size();
  if (c >= b) {
    cout << "YES" << endl;
    for (int i = 0; i < b; i++) {
      int d = find(m.begin(), m.end(), v[i]) - m.begin();
      arr[i] = d + 1;
    }
    sort(arr, arr + b);
    for (int i = 0; i < b; i++) cout << arr[i] << " ";
  } else
    cout << "NO";
  return 0;
}
