結果
| 問題 |
No.207 世界のなんとか
|
| コンテスト | |
| ユーザー |
iodo_shiba
|
| 提出日時 | 2018-08-08 14:09:41 |
| 言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 5,000 ms |
| コード長 | 384 bytes |
| コンパイル時間 | 382 ms |
| コンパイル使用メモリ | 55,260 KB |
| 実行使用メモリ | 6,944 KB |
| 最終ジャッジ日時 | 2024-09-22 14:10:15 |
| 合計ジャッジ時間 | 1,086 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 19 |
ソースコード
#include<iostream>
int main(){
int A,B;
std::cin >> A >> B;
for(int i=A;i<=B;i++){
bool multipleOf3 = i%3==0;
bool contains3=false;
int t=i;
while(t>0){
contains3=contains3||(t%10==3);
t=static_cast<int>(t/10);
}
if(multipleOf3||contains3){
std::cout << i << std::endl;
}
}
}
iodo_shiba