結果
問題 |
No.8023 素数判定するだけ
|
ユーザー |
![]() |
提出日時 | 2017-03-31 22:46:34 |
言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 254 bytes |
コンパイル時間 | 537 ms |
コンパイル使用メモリ | 63,232 KB |
実行使用メモリ | 5,376 KB |
最終ジャッジ日時 | 2024-07-07 05:01:57 |
合計ジャッジ時間 | 4,161 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | WA * 25 |
ソースコード
#include <iostream> using namespace std; int i; int main(){ int N; cin>>N; i++; bool p=true; for(i++;i<N;i++){ if(!(N%i)){ p=false; break; } } cout<<(p?"YES":"NO")<<endl; return 0; }