比赛 20251022赛前模拟1 评测结果 AAAAAAAAAAAAAAAAAAAA
题目名称 正负游戏 最终得分 100
用户昵称 李金泽 运行时间 0.032 s
代码语言 C++ 内存使用 1.64 MiB
提交时间 2025-10-22 09:12:22
显示代码纯文本
#include<cstdio>
#include<cstdlib>
#include<cstring>
#define N 1
#define fo(i,l,r) for(int i=l;i<=r;i++)
#define rf(i,r,l) for(int i=r;i>=l;i--)
#define ll long long
using namespace std;
ll n,m,k;const ll mod=998244353;
ll fp(ll n)
{
	ll ans=1;ll a=2;
	while(n)
	{
		if(n&1)ans=ans*a%mod;
		a=a*a%mod;
		n>>=1;
	}
	return ans;
}
void swap(int &x,int &y){int t=x;x=y;y=t;}
int max(int x,int y){return x>y?x:y;}
int min(int x,int y){return x<y?x:y;}
int read(){
	int sum=0;bool f=0;char c=getchar();
	for(;c<48||c>57;c=getchar())if(c==45)f=1;
	for(;c>=48&&c<=57;c=getchar())sum=sum*10+(c&15);
	return f?-sum:sum;
}
int main(){
	freopen("plusminus.in","r",stdin);freopen("plusminus.out","w",stdout);
	scanf("%lld%lld%lld",&n,&m,&k);
	if((n&1)!=(m&1))return !printf("0");
	printf("%lld\n",fp(n*m-n-m-k+1));
	return 0;
}