結果
問題 | No.207 世界のなんとか |
ユーザー |
![]() |
提出日時 | 2018-07-17 21:02:12 |
言語 | C++11 (gcc 13.3.0) |
結果 |
AC
|
実行時間 | 2 ms / 5,000 ms |
コード長 | 469 bytes |
コンパイル時間 | 639 ms |
コンパイル使用メモリ | 54,036 KB |
実行使用メモリ | 5,248 KB |
最終ジャッジ日時 | 2024-11-27 06:55:20 |
合計ジャッジ時間 | 1,117 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 19 |
ソースコード
#include <iostream> using namespace std; bool isInclude3(int n) { while (true) { if (n % 10 == 3) { return true; } if (n / 10 == 3) { return true; } if (n < 10) { return false; } n /= 10; } } int main() { int a,b; cin>>a>>b; for(int i=a;i<=b;i++){ if(i%3==0 || isInclude3(i)){ cout<<i<<"\n"; } } }