General
 
 
# Author Problem Lang Verdict Time Memory Sent Judged  
188291480 Practice:
DaiRuiChen007
1551D1 - 52 C++14 (GCC 6-32) Accepted 15 ms 8 KB 2023-01-07 10:54:26 2023-01-07 10:54:26
→ Source
// LUOGU_RID: 98929070
#include<bits/stdc++.h> 
using namespace std;
inline void solve() {
	int n,m,k;
	scanf("%d%d%d",&n,&m,&k);
	if(n%2==0&&m%2==1) {
		if(k>n*(m/2)) puts("NO");
		else {
			if(k%2==0) puts("YES");
			else puts("NO");	
		}
	}
	if(n%2==1&&m%2==0) {
		if(k<m/2) puts("NO");
		else {
			if((k-m/2)%2==0) puts("YES");
			else puts("NO");
		}
	}
	if(n%2==0&&m%2==0) {
		if(k%2==0) puts("YES");
		else puts("NO");
	}
}
signed main() {
	int T;
	scanf("%d",&T);
	while(T--) solve();
	return 0;
}
?
Time: ? ms, memory: ? KB
Verdict: ?
Input
?
Participant's output
?
Jury's answer
?
Checker comment
?
Diagnostics
?
Click to see test details