#include <iostream>
int main() {
size_t m, n;
std::cin >> m >> n;
while (m <= n) {
if (m % 3 == 2)
std::cout << m << ' ';
++m;
}