#include <bits/stdc++.h>
int a, b;
std::vector<int> dfs(int b) {
  std::vector<int> path;
  if (b == a) {
    return {a};
  } else if (b < a) {
    return {};
  } else if (b % 2 == 0) {
    path = dfs(b / 2);
  } else if (b % 10 == 1) {
    path = dfs((b - 1) / 10);
  }
  path.push_back(b);
  return std::move(path);
}
int main(int argc, char** argv) {
  std::cin.tie(0);
  std::ios_base::sync_with_stdio(0);
  std::cin >> a >> b;
  std::vector<int> path = dfs(b);
  if (!path.empty() && path.front() == a) {
    std::cout << "YES" << std::endl;
    std::cout << path.size() << std::endl;
    for (const auto& i : path) std::cout << i << ' ';
    std::cout << std::endl;
  } else {
    std::cout << "NO" << std::endl;
  }
  return 0;
}
