问题标题: 酷町堂:1902 奇偶数抓阄游戏

0
0
已解决
李沐阳
李沐阳
初级守护
初级守护

题目链接: 酷町堂:1902

#include<iostream>
#include<cstdio>
int y[201][201],w[201][201],m,n,a,b,s;
using namespace std;
int main(){
    cin>>m>>n;
    for(int i=1;i<=m;i++){
        for(int t=1;t<=n;t++){
            cin>>y[i][t];
        }
    }
    for(int i=1;i<=m;i++){
        for(int t=1;t<=n;t++){
            cin>>w[i][t];
        }
    }
    for(int i=1;i<=m;i++){
        for(int t=1;t<=n;t++){
            if((y[i][t]+w[i][t])%2==1){
                s++;
            }
        }
    }
    cout<<s;
    return 0;
}

RUNTIME ERROR!!!!!!!!!!!!!!!!!!!!!!!!!!

I LIKE MC!


0
已采纳
熊潇然
熊潇然
初级启示者
初级启示者

什么玩意,是一维数组,你咋搞二维?

0
潘登
潘登
高级天翼
高级天翼

一维数组,你为什么会写出二维数组

我要回答