#include <bits/stdc++.h>
using namespace std;
vector<vector<vector<bool> > > board;
bool travel(int m, vector<int> &v, int currsum, bool toggle, vector<int> &moves,
            int last) {
  if (!m) {
    cout << "YES\n";
    for (int i = 0; i < moves.size(); i++) cout << moves[i] << " ";
    return true;
  }
  if (board[m][last][currsum + 15]) return false;
  for (int i = 0; i < v.size(); i++) {
    if (v[i] == last) continue;
    if (toggle) {
      if (currsum + v[i] > 0) {
        moves.push_back(v[i]);
        currsum += v[i];
        if (travel(m - 1, v, currsum, 1 - toggle, moves, v[i]))
          return true;
        else {
          moves.pop_back();
          currsum -= v[i];
        }
      }
    } else {
      if (currsum - v[i] < 0) {
        moves.push_back(v[i]);
        currsum -= v[i];
        if (travel(m - 1, v, currsum, 1 - toggle, moves, v[i]))
          return true;
        else {
          moves.pop_back();
          currsum += v[i];
        }
      }
    }
  }
  board[m][last][currsum + 15] = true;
  return false;
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  int n, val;
  string s;
  cin >> s >> n;
  vector<int> v;
  for (int i = 0; i < s.size(); i++)
    if (s[i] == '1') v.push_back(i + 1);
  int currsum = 0;
  vector<int> moves;
  board.assign(n + 1, vector<vector<bool> >(11, vector<bool>(22, 0)));
  for (int i = 0; i < v.size(); i++) {
    currsum = v[i];
    moves.push_back(v[i]);
    if (travel(n - 1, v, currsum, 0, moves, v[i]))
      return 0;
    else
      moves.pop_back();
  }
  cout << "NO\n";
}
