結果
| 問題 |
No.36 素数が嫌い!
|
| コンテスト | |
| ユーザー |
notetonous
|
| 提出日時 | 2016-06-16 12:10:15 |
| 言語 | C90 (gcc 12.3.0) |
| 結果 |
AC
|
| 実行時間 | 101 ms / 5,000 ms |
| コード長 | 279 bytes |
| コンパイル時間 | 155 ms |
| コンパイル使用メモリ | 20,864 KB |
| 実行使用メモリ | 5,376 KB |
| 最終ジャッジ日時 | 2024-06-27 00:46:47 |
| 合計ジャッジ時間 | 1,487 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 4 |
| other | AC * 26 |
コンパイルメッセージ
main.c: In function ‘main’:
main.c:5:4: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
5 | scanf("%lld",&N);
| ^~~~~~~~~~~~~~~~
ソースコード
#include <stdio.h>
int main(){
long long int N;
long long int i,j,count=0;
scanf("%lld",&N);
for(i=2;i*i<=N;i++){
while(N%i==0){
N/=i;
count++;
}
}
if(N>1)count++;
if(count>=3)printf("YES\n");
else printf("NO\n");
return 0;
}
notetonous