#include <bits/stdc++.h>
using namespace std;
int sit[105][5];
int main() {
  int n, m;
  scanf("%d%d", &n, &m);
  int now = n;
  int hen = 1;
  for (int i = 1; i <= m; i++) {
    if (i & 1) {
      if (hen == 1)
        sit[now][1] = i;
      else
        sit[now][2] = i;
    } else {
      if (hen == 1)
        sit[now--][4] = i;
      else
        sit[now--][3] = i;
    }
    if (i == 2 * n) {
      hen = 2;
      now = n;
    }
  }
  int x = n, y = 2;
  for (int i = 1; i <= m; i++) {
    if (sit[x][y] == 0) {
      i--;
      if (y == 2)
        y--;
      else if (y == 1)
        y = 3;
      else if (y == 3)
        y++;
      else if (y == 4) {
        x--;
        y = 2;
      }
      continue;
    }
    if (i != 1) printf(" ");
    printf("%d", sit[x][y]);
    if (y == 2)
      y--;
    else if (y == 1)
      y = 3;
    else if (y == 3)
      y++;
    else if (y == 4) {
      x--;
      y = 2;
    }
  }
  puts("");
  return 0;
}
