#include <bits/stdc++.h>
using namespace std;
int main() {
  int k[10000], i = 0;
  long long a, b;
  cin >> a >> b;
  while (a < b) {
    if (b % 2 == 0) {
      b /= 2;
      k[i] = 0;
    } else if (b % 10 == 1) {
      b /= 10;
      k[i] = 1;
    } else {
      cout << "NO";
      return 0;
    }
    i++;
  }
  if (a == b) {
    cout << "YES" << endl;
    cout << i + 1 << endl;
    cout << a << " ";
    for (int j = i - 1; j >= 0; j--)
      if (k[j] == 0) {
        a *= 2;
        cout << a << " ";
      } else {
        a = a * 10 + 1;
        cout << a << " ";
      }
  } else
    cout << "NO";
  return 0;
}
