結果

問題 No.1586 Equal Array
ユーザー keisuke6
提出日時 2022-08-30 07:33:08
言語 C++17
(gcc 13.3.0 + boost 1.87.0)
結果
AC  
実行時間 47 ms / 1,000 ms
コード長 251 bytes
コンパイル時間 1,846 ms
コンパイル使用メモリ 192,180 KB
最終ジャッジ日時 2025-02-06 23:50:46
ジャッジサーバーID
(参考情報)
judge1 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 20
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <bits/stdc++.h>
using namespace std;
#define int long long
signed main(){
  int N;
  cin>>N;
  int sum = 0;
  for(int i=0;i<N;i++){
      int a;
      cin>>a;
      sum += a;
  }
  if(sum%N == 0) cout<<"Yes"<<endl;
  else cout<<"No"<<endl;
}
0