Language: C++

#include <bits/stdc++.h> using namespace std;
int N, A[3][3], b[10]; bool appear[3][3];
int main() {
for(int i = 0; i < 3; i++) {
 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30
for(int j = 0; j < 3; j++) cin >> A[i][j];
cin >> N;
for(int i = 0; i < N; i++) cin >> b[i]; for(int i = 0; i < N; i++) {
for(int j = 0; j < N; j++) { appear[i][j] = false;
for(int k = 0; k < N; k++) {
if(A[i][j] == b[k]) appear[i][j] = true; }
} }
string ANS = "No";
for(int i = 0; i < 3; i++) {
if(appear[i][0] and appear[i][1] and appear[i][2]) ANS = "Yes"; }
for(int i = 0; i < 3; i++) {
if(appear[0][i] and appear[1][i] and appear[2][i]) ANS = "Yes";
}
if(appear[0][0] and appear[1][1] and appear[2][2]) ANS = "Yes"; if(appear[0][2] and appear[1][1] and appear[2][0]) ANS = "Yes"; cout << ANS << endl;
return 0;
1
2
3
4
5
6
7 8}
}

Compiler output:
a.cc:1:26: warning: extra tokens at end of #include directive
    1 | #include <bits/stdc++.h> using namespace std;
      |                          ^~~~~
a.cc: In function 'int main()':
a.cc:5:3: error: expected ';' before numeric constant
    5 |  9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30
      |   ^~~
      |   ;
a.cc:6:16: error: 'j' was not declared in this scope
    6 | for(int j = 0; j < 3; j++) cin >> A[i][j];
      |                ^
a.cc:7:1: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    7 | cin >> N;
      | ^~~
      | std::cin
In file included from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:146,
                 from a.cc:1:
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
a.cc:13:1: error: 'string' was not declared in this scope
   13 | string ANS = "No";
      | ^~~~~~
a.cc:13:1: note: suggested alternatives:
In file included from /usr/include/c++/14/string:41,
                 from /usr/include/c++/14/bitset:52,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:52:
/usr/include/c++/14/bits/stringfwd.h:77:33: note:   'std::string'
   77 |   typedef basic_string<char>    string;
      |                                 ^~~~~~
/usr/include/c++/14/string:76:11: note:   'std::pmr::string'
   76 |     using string    = basic_string<char>;
      |           ^~~~~~
a.cc:15:52: error: 'ANS' was not declared in this scope
   15 | if(appear[i][0] and appear[i][1] and appear[i][2]) ANS = "Yes"; }
      |                                                    ^~~
a.cc:17:52: error: 'ANS' was not declared in this scope
   17 | if(appear[0][i] and appear[1][i] and appear[2][i]) ANS = "Yes";
      |                                                    ^~~
a.cc:19:52: error: 'ANS' was not declared in this scope
   19 | if(appear[0][0] and appear[1][1] and appear[2][2]) ANS = "Yes"; if(appear[0][2] and appear[1][1] and appear[2][0]) ANS = "Yes"; cout << ANS << endl;
      |                                                    ^~~
a.cc:19:116: error: 'ANS' was not declared in this scope
   19 | if(appear[0][0] and appear[1][1] and appear[2][2]) ANS = "Yes"; if(appear[0][2] and appear[1][1] and appear[2][0]) ANS = "Yes"; cout << ANS << endl;
      |                                                                                                                    ^~~
a.cc:19:129: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   19 | if(appear[0][0] and appear[1][1] and appear[2][2]) ANS = "Yes"; if(appear[0][2] and appear[1][1] and appear[2][0]) ANS = "Yes"; cout << ANS << endl;
      |                                                                                                                                 ^~~~
      |                                                                                                                                 std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:19:137: error: 'ANS' was not declared in this scope
   19 | if(appear[0][0] and appear[1][1] and appear[2][2]) ANS = "Yes"; if(appear[0][2] and appear[1][1] and appear[2][0]) ANS = "Yes"; cout << ANS << endl;
      |                                                                                                                                         ^~~
a.cc:19:144: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   19 | if(appear[0][0] and appear[1][1] and appear[2][2]) ANS = "Yes"; if(appear[0][2] and appear[1][1] and appear[2][0]) ANS = "Yes"; cout << ANS << endl;
      |                                                                                                                                                ^~~~
      |                                                                                                                                                std::endl
In file included from /usr/include/c++/14/istream:41,
                 from /usr/include/c++/14/sstream:40,
                 from /usr/include/c++/14/complex:45,
                 from /usr/include/c++/14/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:127:
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
a.cc:21:2: error: expected ';' before numeric constant
   21 | 1
      |  ^
      |  ;
   22 | 2
      | ~