結果
問題 |
No.312 置換処理
|
ユーザー |
![]() |
提出日時 | 2016-03-03 17:59:19 |
言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
結果 |
TLE
|
実行時間 | - |
コード長 | 298 bytes |
コンパイル時間 | 166 ms |
コンパイル使用メモリ | 22,784 KB |
実行使用メモリ | 13,760 KB |
最終ジャッジ日時 | 2024-09-24 13:48:58 |
合計ジャッジ時間 | 3,613 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 1 TLE * 1 -- * 43 |
コンパイルメッセージ
main.cpp: In function ‘int main()’: main.cpp:16:19: warning: format ‘%d’ expects argument of type ‘int’, but argument 2 has type ‘ll’ {aka ‘long long int’} [-Wformat=] 16 | printf( "%d\n", N ); | ~^ ~ | | | | int ll {aka long long int} | %lld main.cpp:11:14: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 11 | scanf( "%lld", &N ); | ~~~~~^~~~~~~~~~~~~~
ソースコード
// yukicoder 312 (http://yukicoder.me/problems/847) #include<cstdio> #define rep(i,a) for(int i=0;i<(a);++i) typedef long long ll; ll N; int main() { scanf( "%lld", &N ); for( int i = 3; i*i <= N; ++i ) if( N % i == 0 ) { printf( "%d\n", i ); return 0; } printf( "%d\n", N ); return 0; }