#include <bits/stdc++.h>
using namespace std;
int a[4][110];
int main() {
  for (int i = 0; i < 4; i++) {
    for (int j = 0; j < 110; j++) a[i][j] = -1;
  }
  int n, m;
  cin >> n >> m;
  int cur = 0, left = 0, right = 3;
  for (int i = 1; i <= m;) {
    a[left][cur] = i;
    if (i + 1 <= m) a[right][cur] = i + 1;
    i += 2;
    cur++;
    if (cur == n) {
      cur = 0;
      left = 1;
      right = 2;
    }
  }
  cur = 0;
  for (int i = 0; i < n; i++) {
    if (a[1][i] != -1) cout << a[1][i] << " ";
    if (a[0][i] != -1) cout << a[0][i] << " ";
    if (a[2][i] != -1) cout << a[2][i] << " ";
    if (a[3][i] != -1) cout << a[3][i] << " ";
  }
  return 0;
}
