1 条题解

  • 0
    @ 2026-8-7 16:24:48
    #include<bits/stdc++.h>
    using namespace std;
    typedef long long ll;
    const int mod=998244353;
    int n,m,k;
    bitset<10010> a[10010],b[10010],c[10010];
    int main(){
    	ios::sync_with_stdio(0);
    	cin.tie(0);
    	cin>>n>>m>>k;
    	for(int i=1;i<=n;i++){
    		string s;
    		cin>>s;
    		for(int j=1;j<=m;j++){
    			a[i][j]=s[j-1]-'0';
    		}
    	}
    	for(int i=1;i<=m;i++){
    		string s;
    		cin>>s;
    		for(int j=1;j<=k;j++){
    			b[i][j]=s[j-1]-'0';
    		}
    	}
    	for(int i=1;i<=n;i++){
    		for(int j=1;j<=m;j++){
    			if(a[i][j])c[i]^=b[j];
    		}
    	}
    	for(int i=1;i<=n;i++){
    		for(int j=1;j<=k;j++){
    			cout<<c[i][j];
    		}
    		cout<<'\n';
    	}
    	return 0;
    }
    
    • 1

    信息

    ID
    3311
    时间
    2000ms
    内存
    1024MiB
    难度
    10
    标签
    递交数
    7
    已通过
    3
    上传者