# Feedback for ZOOZ problem

Problem Link: ZOOZ Problem - CodeChef

### Feedback

include
include
include
include
using namespace std;
// Remember *max_element(c,c+n) and s.find()

define shit int t;cin>>t;while(t–)
define pi 3.141597653
define o 0
define l 1
define el endl
define loop(j,a,b) for(int j=a; j<b; j++)
define inn int n;cin>>n

int main(){
shit{
inn;
string s1 = “1001”;
string s2 = “010”;
string s3 = “01”;
string s4 = “10”;
string ans;
int i=0;
if(n>=3){
if(n%2==0){
while(i<(n-4)/2){
s1+= s3;
i++;
}
cout<<s1<<el;
}
else{
while(i<(n-3)/2){
s2+= s4;
i++;
}
cout<<s2<<el;
}
}

``````}
``````

}

I don’t see any problem in any test case from this approach. It’s withing time limit too. Then why isn’t this accepted as the right answer??

@umang03r
your code is not right and logic is also not right.
like its correct for if 01 and 10 are substrings since they where subsequence its not right.
the correct logic would be if n id odd print 1 in the middle else print two ones at the end thats it

1 Like

Understood thnx!