#include #include #include #include #include #include #include #include #include #include #include #include #include #include using namespace std; int main() { int32_t a, b; cin >> a >> b; for (auto i = 0; i < b; ++i) { for (auto j = 0; j < min(a + 1, 5); ++j) { if (i * 5 + j == 0) continue; cout << i * 5 + j << endl; } } for (auto i = 0; i <= a; ++i) { if (b * 5 + i == 0) continue; cout << b * 5 + i << endl; } return 0; }