結果
問題 |
No.476 正しくない平均
|
ユーザー |
![]() |
提出日時 | 2020-03-13 17:24:07 |
言語 | C (gcc 13.3.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 294 bytes |
コンパイル時間 | 169 ms |
コンパイル使用メモリ | 29,184 KB |
実行使用メモリ | 5,248 KB |
最終ジャッジ日時 | 2024-11-22 10:19:08 |
合計ジャッジ時間 | 1,185 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 19 WA * 7 |
ソースコード
#include<stdio.h> #include<string.h> #include<stdlib.h> int main(void){ int n,a,x[15]; scanf("%d %d",&n,&a); int sum=0; for(int i=0;i<n;i++){ scanf("%d",&x[i]); sum=sum+x[i]; } if((long long int)sum==(long long int)a*n){printf("YES\n");} else{printf("NO\n");} }