/** * author: TakeruOkuyama * created: 2020-04-09 14:53:46 **/ #include #define rep(i, n) for(int i = 0; i < (n); i++) using namespace std; using ll = long long; using P = pair; const int MOD = 1000000007; int main(){ int A, B; cin >> A >> B; for(int i = A; i <= B; i++){ if(i % 3 == 0){ cout << i << endl; continue; } string S = to_string(i); rep(j, S.size()){ if(S.at(j) == '3'){ cout << i << endl; continue; } } } return 0;} /** * g++ code.cpp * ./a.out * shift + ctrl + i **/