https://www.codechef.com/problems/ISITCAKE

https://www.codechef.com/problems/ISITCAKE Guys What is wrong with my code. Its showing me WRONG ANSWER after submission.

#include<iostream>
        using namespace std;
        int main(){
        int t;
        cin>>t;
        for(int i=0;i<t;i++){
            int a[10][10],count=0;
            for(int j=0;j<10;j++){
                for(int k=0;k<10;k++){
                    cin>>a[j][k];
                    if(a[j][k]<=30)
                    count++;
                }
                cout<<"\n";
                
            }
        if(count>60)
        cout<<"yes"<<endl;
        else 
        cout<<"no"<<endl;
            
        }
        return 0;
        }

remove cout << “\n” in for loop of j and make “count >= 60”

1 Like

Thanks…it worked!!!

Cout statement does not enter