結果
問題 | No.207 世界のなんとか |
ユーザー |
![]() |
提出日時 | 2018-02-25 15:34:02 |
言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
結果 |
AC
|
実行時間 | 1 ms / 5,000 ms |
コード長 | 265 bytes |
コンパイル時間 | 218 ms |
コンパイル使用メモリ | 29,824 KB |
実行使用メモリ | 6,820 KB |
最終ジャッジ日時 | 2024-11-14 04:02:21 |
合計ジャッジ時間 | 866 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 19 |
コンパイルメッセージ
main.cpp: In function ‘int main()’: main.cpp:6:14: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 6 | scanf("%d%d",&a,&b); | ~~~~~^~~~~~~~~~~~~~
ソースコード
#include<cstdio>#include<cmath>int main(){int a,b,i,t,f;scanf("%d%d",&a,&b);for(i=a;i<=b;i++){f=0;if(i%3==0)f=1;//3の倍数かチェックfor(t=i;t;t/=10)if(t%10==3)f=1;//3を含むかチェックif(f==1)printf("%d\n",i);}return 0;}