#include <bits/stdc++.h>
using namespace std;
int main() {
  int u, d;
  cin >> u;
  cin >> d;
  int r = u - d;
  int prev;
  if (r >= 0) {
    prev = 1;
    cout << prev << " ";
    while (u > 0) {
      prev = prev + (r-- > 0 ? 1 : 2);
      cout << prev << " ";
      u--;
    }
    if (d > 0) {
      prev = prev - 1;
      cout << prev << " ";
      d--;
    }
    while (d > 0) {
      prev = prev - 2;
      cout << prev << " ";
      d--;
    }
  } else {
    r *= -1;
    prev = 1 + r;
    cout << prev << " ";
    while (u > 0) {
      prev = prev + 2;
      cout << prev << " ";
      u--;
    }
    if (d > 0) {
      prev = prev - 1;
      cout << prev << " ";
      d--;
    }
    while (d > 0) {
      prev = prev - (prev > 1 + r ? 2 : 1);
      cout << prev << " ";
      d--;
    }
  }
  return 0;
}
