#include <bits/stdc++.h>
int main() {
  size_t n, m;
  scanf("%zu %zu", &n, &m);
  std::vector<std::stack<int>> s(2 * n);
  for (size_t i = 0; i < m; ++i) {
    s[i % (2 * n)].push(i + 1);
  }
  std::vector<int> res;
  for (size_t i = 0; i < 2 * n; ++i)
    while (!s[i].empty()) {
      res.push_back(s[i].top());
      s[i].pop();
    }
  for (size_t i = 0; i < m; ++i) printf("%d%c", res[i], i + 1 < m ? ' ' : '\n');
}
