結果

問題 No.36 素数が嫌い!
ユーザー twice_l
提出日時 2017-12-28 00:03:00
言語 C++11(廃止可能性あり)
(gcc 13.3.0)
結果
WA  
実行時間 -
コード長 371 bytes
コンパイル時間 626 ms
コンパイル使用メモリ 62,184 KB
実行使用メモリ 6,824 KB
最終ジャッジ日時 2024-12-21 08:17:08
合計ジャッジ時間 2,471 ms
ジャッジサーバーID
(参考情報)
judge2 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3 WA * 1
other AC * 16 WA * 10
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <iostream>
#include <vector>
#include <cmath>

using namespace std;

int main()
{
  long long N;
  cin >> N;

  int count = 0;
  for(int i=2; i<=sqrt(N); ++i){
    while(N%i == 0){
      N /= i;
      ++count;
      if(count == 3){
        cout << "YES" << endl;
        return 0;
      }
    }
  }
  cout << "NO" << endl;
  return 0;
}
0