#include <bits/stdc++.h>
using namespace std;
string s;
int m;
void dfs(int curBalance, int prev, int k, int ans[]) {
  if (k > m) {
    cout << "YES" << endl;
    for (int i = 0; i < m; i++) cout << ans[i] << " ";
    exit(0);
  }
  for (int i = 0; i < s.size(); i++) {
    if (s[i] == '1' && i + 1 > curBalance && i + 1 != prev) {
      ans[k - 1] = i + 1;
      dfs(i + 1 - curBalance, i + 1, k + 1, ans);
    }
  }
}
int main() {
  cin >> s >> m;
  int ans[1005];
  dfs(0, 0, 1, ans);
  cout << "NO";
  return 0;
}
