Language: C++

#include <bits/stdc++.h>

using namespace std;

#define endl '\n'
#define ll long long

const ll mod = 1e9 + 7;
const ll maxn = 2e5 + 5;
const double pi = 3.1415926535897932384626433832795028841971693993751058209749445923078;
//iostream::sync_with_stdio(false);

int main()
{
    int m[10];
    int x;
    for(int i = 1; i <= 3; i++)
    {
        for(int j = 1; j <= 3; j++)
        {
            cin >> m[i][j];
        }
    }
    int n;
    cin >> n;
    for(int k = 1; k <= n; k++)
    {
        cin >> x;
        for(int i = 1; i <= 3; i++)
        {
            for(int j = 1; j <= 3; j++)
            {
                if(m[i][j] == x)
                {
                    m[i][j] = 0;
                }
            }
        }
    }
    if(m[1][1]==0&&m[1][2]==0&&m[1][3]==0)
    {
        cout << "Yes" << endl;
    }
    else if(m[2][1]==0&&m[2][2]==0&&m[2][3]==0)
    {
        cout << "Yes" << endl;
    }
    else if(m[3][1]==0&&m[3][2]==0&&m[3][3]==0)
    {
        cout << "Yes" << endl;
    }
    else if(m[1][1]==0&&m[2][1]==0&&m[3][1]==0)
    {
        cout << "Yes" << endl;
    }
    else if(m[1][2]==0&&m[2][2]==0&&m[3][2]==0)
    {
        cout << "Yes" << endl;
    }
    else if(m[1][3]==0&&m[2][3]==0&&m[3][3]==0)
    {
        cout << "Yes" << endl;
    }
    else if(m[1][1]==0&&m[2][2]==0&&m[3][3]==0)
    {
        cout << "Yes" << endl;
    }
    else if(m[1][3]==0&&m[2][2]==0&&m[3][1]==0)
    {
        cout << "Yes" << endl;
    }
    else
    {
        cout << "No" << endl;
    }
    return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:21:24: error: invalid types 'int[int]' for array subscript
   21 |             cin >> m[i][j];
      |                        ^
a.cc:33:24: error: invalid types 'int[int]' for array subscript
   33 |                 if(m[i][j] == x)
      |                        ^
a.cc:35:25: error: invalid types 'int[int]' for array subscript
   35 |                     m[i][j] = 0;
      |                         ^
a.cc:40:12: error: invalid types 'int[int]' for array subscript
   40 |     if(m[1][1]==0&&m[1][2]==0&&m[1][3]==0)
      |            ^
a.cc:40:24: error: invalid types 'int[int]' for array subscript
   40 |     if(m[1][1]==0&&m[1][2]==0&&m[1][3]==0)
      |                        ^
a.cc:40:36: error: invalid types 'int[int]' for array subscript
   40 |     if(m[1][1]==0&&m[1][2]==0&&m[1][3]==0)
      |                                    ^
a.cc:44:17: error: invalid types 'int[int]' for array subscript
   44 |     else if(m[2][1]==0&&m[2][2]==0&&m[2][3]==0)
      |                 ^
a.cc:44:29: error: invalid types 'int[int]' for array subscript
   44 |     else if(m[2][1]==0&&m[2][2]==0&&m[2][3]==0)
      |                             ^
a.cc:44:41: error: invalid types 'int[int]' for array subscript
   44 |     else if(m[2][1]==0&&m[2][2]==0&&m[2][3]==0)
      |                                         ^
a.cc:48:17: error: invalid types 'int[int]' for array subscript
   48 |     else if(m[3][1]==0&&m[3][2]==0&&m[3][3]==0)
      |                 ^
a.cc:48:29: error: invalid types 'int[int]' for array subscript
   48 |     else if(m[3][1]==0&&m[3][2]==0&&m[3][3]==0)
      |                             ^
a.cc:48:41: error: invalid types 'int[int]' for array subscript
   48 |     else if(m[3][1]==0&&m[3][2]==0&&m[3][3]==0)
      |                                         ^
a.cc:52:17: error: invalid types 'int[int]' for array subscript
   52 |     else if(m[1][1]==0&&m[2][1]==0&&m[3][1]==0)
      |                 ^
a.cc:52:29: error: invalid types 'int[int]' for array subscript
   52 |     else if(m[1][1]==0&&m[2][1]==0&&m[3][1]==0)
      |                             ^
a.cc:52:41: error: invalid types 'int[int]' for array subscript
   52 |     else if(m[1][1]==0&&m[2][1]==0&&m[3][1]==0)
      |                                         ^
a.cc:56:17: error: invalid types 'int[int]' for array subscript
   56 |     else if(m[1][2]==0&&m[2][2]==0&&m[3][2]==0)
      |                 ^
a.cc:56:29: error: invalid types 'int[int]' for array subscript
   56 |     else if(m[1][2]==0&&m[2][2]==0&&m[3][2]==0)
      |                             ^
a.cc:56:41: error: invalid types 'int[int]' for array subscript
   56 |     else if(m[1][2]==0&&m[2][2]==0&&m[3][2]==0)
      |                                         ^
a.cc:60:17: error: invalid types 'int[int]' for array subscript
   60 |     else if(m[1][3]==0&&m[2][3]==0&&m[3][3]==0)
      |                 ^
a.cc:60:29: error: invalid types 'int[int]' for array subscript
   60 |     else if(m[1][3]==0&&m[2][3]==0&&m[3][3]==0)
      |                             ^
a.cc:60:41: error: invalid types 'int[int]' for array subscript
   60 |     else if(m[1][3]==0&&m[2][3]==0&&m[3][3]==0)
      |                                         ^
a.cc:64:17: error: invalid types 'int[int]' for array subscript
   64 |     else if(m[1][1]==0&&m[2][2]==0&&m[3][3]==0)
      |                 ^
a.cc:64:29: error: invalid types 'int[int]' for array subscript
   64 |     else if(m[1][1]==0&&m[2][2]==0&&m[3][3]==0)
      |                             ^
a.cc:64:41: error: invalid types 'int[int]' for array subscript
   64 |     else if(m[1][1]==0&&m[2][2]==0&&m[3][3]==0)
      |                                         ^
a.cc:68:17: error: invalid types 'int[int]' for array subscript
   68 |     else if(m[1][3]==0&&m[2][2]==0&&m[3][1]==0)
      |                 ^
a.cc:68:29: error: invalid types 'int[int]' for array subscript
   68 |     else if(m[1][3]==0&&m[2][2]==0&&m[3][1]==0)
      |                             ^
a.cc:68:41: error: invalid types 'int[int]' for array subscript
   68 |     else if(m[1][3]==0&&m[2][2]==0&&m[3][1]==0)
      |                                         ^