#39101: c++ans 非常厲害


aidenlin766909@gmail.com (aiden lin)

School : No School
ID : 245101
IP address : [1.163.70.171]
Last Login :
2024-05-11 20:03:22
a148. You Cannot Pass?! | From: [223.140.133.92] | Post Date : 2024-01-13 18:32

#include <iostream>
using namespace std;

int main() 
{
    int n;
    while (cin >> n) 
    {
      int x, sum = 0;
      for (int i = 0; i < n; i++) 
      {
        cin >> x;
        sum += x;
      }
      if (sum > 59 * n) 
      {
        cout << "no"<<endl;
      } 
      else
      {
        cout << "yes"<<endl;
      }
    }
}

 
ZeroJudge Forum