#include <bits/stdc++.h>
int main() {
  long long a, b, k = 0;
  bool flag = true;
  std::stack<long long> st;
  std::cin >> a >> b;
  st.push(b);
  while (b > a && flag) {
    if (b % 10 == 1) {
      b = b / 10;
      st.push(b);
      k++;
    } else if (b % 2 == 0) {
      b = b / 2;
      st.push(b);
      k++;
    } else {
      flag = false;
    }
  }
  if (!flag || b != a) {
    std::cout << "NO";
  } else {
    std::cout << "YES" << std::endl << k + 1 << std::endl;
    while (!st.empty()) {
      std::cout << st.top() << " ";
      st.pop();
    }
  }
  return 0;
}
