#include <bits/stdc++.h>
using namespace std;
const long long sz = 23;
void solve() {
  long long a, b;
  cin >> a >> b;
  vector<long long> ans;
  while (b > a) {
    ans.push_back(b);
    if (b % 2 == 0)
      b /= 2;
    else {
      if (b % 10 != 1) {
        cout << "NO\n";
        return;
      }
      b /= 10;
    }
  }
  if (b != a) {
    cout << "NO\n";
    return;
  }
  ans.push_back(a);
  reverse(ans.begin(), ans.end());
  cout << "YES\n" << ans.size() << "\n";
  for (auto u : ans) {
    cout << u << ' ';
  }
}
signed main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  cout << fixed;
  cout.precision(30);
  long long t = 1;
  while (t--) solve();
}
