#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  long long a, b;
  cin >> a >> b;
  bool f = false;
  vector<int> ans;
  while (b >= a) {
    ans.push_back(b);
    if (a == b) f = true;
    if (b % 2 == 0)
      b /= 2;
    else {
      string x = to_string(b);
      if (x.back() != '1') break;
      x.pop_back();
      if (x.size())
        b = stoi(x);
      else
        break;
    }
  }
  if (f) {
    cout << "YES\n" << ans.size() << '\n';
    reverse(ans.begin(), ans.end());
    for (auto l : ans) cout << l << " ";
  } else
    cout << "NO\n";
}
