I was trying to solve this problem=lunchtime|TANDJ1
This is what I did can someone please tell me what I was doing wrong
#include <iostream>
#include<cmath>
using namespace std;
int main() {
// your code goes here
int t;
cin>>t;
while(t--){
int a,b,x,y,k;
cin>>a>>b>>x>>y>>k;
int reqs = abs(x-a)+abs(y-b);
if(k < reqs){
cout<<"NO"<<endl;
break;
}
else if(k == reqs){
cout<<"YES"<<endl;
}
else{
int left = k-reqs;
if(left % 2 == 0){
cout<<"YES"<<endl;
}
else{
cout<<"NO"<<endl;
}
}
}
return 0;
}
.