結果
問題 |
No.3023 Utility is Max?
|
ユーザー |
![]() |
提出日時 | 2025-06-12 13:30:36 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 427 bytes |
コンパイル時間 | 604 ms |
コンパイル使用メモリ | 68,224 KB |
実行使用メモリ | 7,848 KB |
最終ジャッジ日時 | 2025-06-12 13:35:22 |
合計ジャッジ時間 | 2,303 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
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; }