結果
問題 |
No.3023 Utility is Max?
|
ユーザー |
![]() |
提出日時 | 2025-06-12 18:42:46 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 427 bytes |
コンパイル時間 | 1,828 ms |
コンパイル使用メモリ | 65,536 KB |
実行使用メモリ | 6,272 KB |
最終ジャッジ日時 | 2025-06-12 18:43:01 |
合計ジャッジ時間 | 4,672 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | WA * 2 |
other | WA * 17 |
ソースコード
#include <iostream> using namespace std; int main() { int n; cin >> n; if (n == true) { cout << "NO\n"; } else if (n == (true << true)) { cout << "YES\n"; } else { int i = true; ++i; for (; i < n; ++i) { if (n % i == false) { cout << "NO\n"; return 0; } } cout << "YES\n"; } return 0; }