Help me in solving AMR15A problem

My issue

can anyone tell me ur approach

My code

#include <stdio.h>

int main(void) {
	// your code goes here
	int t,count=0,count1=0;
	int a[100];
	scanf("%d",&t);
	for(int i=0;i<t;i++){
	    scanf("%d",&a[i]);
	}
	for(int i=0;i<t;i++){
	    if(a[i]%2==0)
	        count+=1;
	    else
	        count1+=1;
	}
	if(count>count1)
	    printf("Ready for battle");
	else
	    printf("Not ready");

}


Problem Link: Mahasena Practice Coding Problem - CodeChef

@msowjanya
plzz refer the following code for better understanding of the logic

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

int main() {
int n,lucky=0,unlucky=0;
cin>>n;
int arr[n];

for(int i=0;i<n;i++){
 cin>>arr[i];
 if(arr[i]%2==0){
     lucky++;
 }
 else{
     unlucky++;
 }
 
}
 if(lucky<=unlucky){
     cout<<"NOT READY";
 }
 else{
     cout<<"READY FOR BATTLE";
 }
 
 
}