結果

問題 No.207 世界のなんとか
ユーザー saikatoto
提出日時 2020-08-11 20:39:36
言語 C++17
(gcc 13.3.0 + boost 1.87.0)
結果
AC  
実行時間 2 ms / 5,000 ms
コード長 319 bytes
コンパイル時間 2,137 ms
コンパイル使用メモリ 191,420 KB
最終ジャッジ日時 2025-01-12 20:25:04
ジャッジサーバーID
(参考情報)
judge2 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 19
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <bits/stdc++.h>
using namespace std;

int main() {
  long long a, b;
  cin >> a >> b;
  
  while(1){
    if(a > b) break;
    bool ok = false;
    if(a % 3 == 0) ok = true;
    long long k = a;
    while(k > 0){
      if(k % 10 == 3) ok = true;
      k /= 10;
    }
    if(ok) cout << a << endl;
    a++;
  }
}
0