QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#750091#5141. Identical Parityckq328WA 0ms3664kbC++20610b2024-11-15 12:35:262024-11-15 12:35:27

Judging History

你现在查看的是最新测评结果

  • [2024-11-15 12:35:27]
  • 评测
  • 测评结果:WA
  • 用时:0ms
  • 内存:3664kb
  • [2024-11-15 12:35:26]
  • 提交

answer

#include <bits/stdc++.h>
#define int long long
using namespace std;
const int N=1e6+10,M=200+10,inf=1e18,mod=998244353;
int n,k;
int a[N],f[N];
void solve(){
	cin>>n>>k;
	if(k==1){
		if(n==1) cout<<"yes"<<endl;
		else cout<<"No"<<endl;
	}
	else if(k%2==0) cout<<"yes"<<endl;
	else{
		if(k==n) cout<<"yes"<<endl;
		else cout<<"no"<<endl;
	}
}
signed main(){
	ios::sync_with_stdio(0);
	cin.tie(0);
	cout.tie(0);
	int tt;
	cin>>tt;
	// tt=1;
	while(tt--){
		solve();
	}
}
/*
1
10
598196518 640274071 983359971 71550121 96204862 799843967 446173607 796619138 402690754 223219513
*/

Details

Tip: Click on the bar to expand more detailed information

Test #1:

score: 0
Wrong Answer
time: 0ms
memory: 3664kb

input:

3
3 1
4 2
5 3

output:

No
yes
no

result:

wrong answer expected YES, found NO [3rd token]