AGC 010 A - Addition 解いてみた
問題はこちら
回答
#include <iostream>
using namespace std;
int main(){
int N;
int A[100000];
cin >> N;
for (int i = 0; i < N; i++) {
cin >> A[i];
}
bool can = true;
int sum = 0;
for (int i = 0; i<N; i++){
sum += A[i];
}
if (sum%2 != 0) can = false;
if (can) cout << "YES" << endl;
else cout << "NO" << endl;
return 0;
}