#include <bits/stdc++.h>
using namespace std;
vector<int> op;
bool dfs(int a, int b) {
  if (b == a) return true;
  if (a > b) return false;
  if (b % 10 == 1) {
    b = (b - 1) / 10;
    op.push_back(2);
    return dfs(a, b);
  } else if (b % 2 == 0) {
    b = (b >> 1);
    op.push_back(1);
    return dfs(a, b);
  } else
    return false;
}
int main() {
  int a, b;
  cin >> a >> b;
  if (dfs(a, b)) {
    cout << "YES\n";
    cout << op.size() + 1 << "\n";
    cout << a << " ";
    for (int i = op.size() - 1; i >= 0; i--) {
      if (op[i] == 1) {
        a = (a * 2);
        cout << a << " ";
      } else {
        a = 10 * a + 1;
        cout << a << " ";
      }
    }
  } else
    cout << "NO";
}
