#include <bits/stdc++.h>
using namespace std;
int main() {
  long long n, m, tmp;
  cin >> n >> m;
  tmp = n + m + 1;
  if (n > m) {
    cout << 1 << ' ';
    for (int x = 2, i = tmp; x <= tmp; x++, i--) {
      if (m != 0) cout << i << ' ', m--;
      if (n != 0) cout << x << ' ', n--;
    }
  } else if (m > n) {
    cout << tmp << ' ';
    for (int x = 1, i = tmp - 1; x <= tmp; x++, i--) {
      if (m != 0) cout << i << ' ', m--;
      if (n != 0) cout << x << ' ', n--;
    }
  } else {
    cout << 1 << ' ';
    for (int x = 2, i = tmp; x <= tmp; x++, i--) {
      if (m != 0) cout << i << ' ', m--;
      if (n != 0) cout << x << ' ', n--;
    }
  }
  return 0;
}
