/ SeriousOJ /

Record Detail

Wrong Answer


  
# Status Time Cost Memory Cost
#1 Accepted 1ms 768.0 KiB
#2 Wrong Answer 27ms 576.0 KiB
#3 Wrong Answer 7ms 532.0 KiB
#4 Wrong Answer 7ms 532.0 KiB
#5 Wrong Answer 36ms 532.0 KiB
#6 Wrong Answer 38ms 536.0 KiB

Code

#include <bits/stdc++.h>
using namespace std;
#define int long long int

main(){
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  int t; cin >> t;
  while(t--){
    int n; cin >> n;
    int cnt1 = 0;
    int cnt2 = 0;
    for(int i = 0; i < n; i++){
      int x; cin >> x;
      if(x % 2) cnt1++;
      else cnt2++;
    }
    if(cnt1 == cnt2) cout << "Hridoy" << endl;
    else{
      if(cnt1 > cnt2) cout << "Roy" << endl;
      else cout << "Hridoy" << endl;
    }
  }
}

Information

Submit By
Type
Submission
Problem
P1102 Odd-Even Game
Language
C++17 (G++ 13.2.0)
Submit At
2024-10-03 18:46:13
Judged At
2024-10-03 18:46:13
Judged By
Score
1
Total Time
38ms
Peak Memory
768.0 KiB