#include <bits/stdc++.h>
using namespace std;
int q[1000000];
int main() {
  int a, b;
  scanf("%d%d", &a, &b);
  if (a > b) swap(a, b);
  int k = 1;
  q[0] = b;
  int flag = 0;
  while (a < b) {
    if (b & 1) {
      b = (b - 1);
      if (!(b % 10))
        b /= 10;
      else {
        flag = 1;
        break;
      }
    } else
      b = b / 2;
    q[k++] = b;
  }
  if (b == a && flag == 0) {
    printf("YES\n");
    printf("%d\n", k);
    for (int i = k - 1; i > 0; i--) printf("%d ", q[i]);
    printf("%d\n", q[0]);
  } else
    printf("NO\n");
  return 0;
}
