Language: C++

#include <bits/stdc++.h>
using namespace std;
int a1[9],a2[9],a3[9],a4[9],a5[9],a6[9],a7[9],a8[9],a[3][3],s,cnt=0;
int main(){
  for(int i=0;i<=2;i++){
    for(int j=0;j<=2;j++)cin>>a[i][j];
  }
  int n;
  cin>>n;
  int s[n];
  for(int i=0;i<n;i++)cin>>s[i];
  for(int i=0;i<=2;i++){
    for(int j=0;j<=2;j++){
      cnt=0;
      s=a[i][j];
      while(s>0){
        ai[cnt]=s%10;
        s=s/10;
        cnt++;
      }
    }
  }
  for(int i=0;i<=2;i++){
    for(int j=0;j<=2;j++){
      s=a[j][i];
      cnt=0;
      while(s>0){
        a(i+3)[cnt]=s%10;
        s=s/10;
        cnt++;
      }
    }
  }
  int g[n*3];
  for(int i=0;i<=2;i++){
    s=a[i][i];
    cnt=0;
    while(s>0){
        a8[cnt]=s%10;
        s=s/10;
        cnt++;
      }
  }
  for(int i=0;i<=2;i++){
    s=a[i][2-i];
    cnt=0;
    while(s>0){
        a9[cnt]=s%10;
        s=s/10;
        cnt++;
      }
  }
  for(int i=0;i<n;i++){
    cnt=0;
    while(s>0){
      s[cnt]=s%10;
      s=s/10;
      cnt++;
    }
  }
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:15:8: error: incompatible types in assignment of 'int' to 'int [n]'
   15 |       s=a[i][j];
      |       ~^~~~~~~~
a.cc:16:14: error: ordered comparison of pointer with integer zero ('int*' and 'int')
   16 |       while(s>0){
      |             ~^~
a.cc:17:9: error: 'ai' was not declared in this scope; did you mean 'i'?
   17 |         ai[cnt]=s%10;
      |         ^~
      |         i
a.cc:17:18: error: invalid operands of types 'int [n]' and 'int' to binary 'operator%'
   17 |         ai[cnt]=s%10;
      |                 ~^~~
      |                 | |
      |                 | int
      |                 int [n]
a.cc:18:12: error: invalid operands of types 'int [n]' and 'int' to binary 'operator/'
   18 |         s=s/10;
      |           ~^~~
      |           | |
      |           | int
      |           int [n]
a.cc:25:8: error: incompatible types in assignment of 'int' to 'int [n]'
   25 |       s=a[j][i];
      |       ~^~~~~~~~
a.cc:27:14: error: ordered comparison of pointer with integer zero ('int*' and 'int')
   27 |       while(s>0){
      |             ~^~
a.cc:28:10: error: 'a' cannot be used as a function
   28 |         a(i+3)[cnt]=s%10;
      |         ~^~~~~
a.cc:28:22: error: invalid operands of types 'int [n]' and 'int' to binary 'operator%'
   28 |         a(i+3)[cnt]=s%10;
      |                     ~^~~
      |                     | |
      |                     | int
      |                     int [n]
a.cc:29:12: error: invalid operands of types 'int [n]' and 'int' to binary 'operator/'
   29 |         s=s/10;
      |           ~^~~
      |           | |
      |           | int
      |           int [n]
a.cc:36:6: error: incompatible types in assignment of 'int' to 'int [n]'
   36 |     s=a[i][i];
      |     ~^~~~~~~~
a.cc:38:12: error: ordered comparison of pointer with integer zero ('int*' and 'int')
   38 |     while(s>0){
      |           ~^~
a.cc:39:18: error: invalid operands of types 'int [n]' and 'int' to binary 'operator%'
   39 |         a8[cnt]=s%10;
      |                 ~^~~
      |                 | |
      |                 | int
      |                 int [n]
a.cc:40:12: error: invalid operands of types 'int [n]' and 'int' to binary 'operator/'
   40 |         s=s/10;
      |           ~^~~
      |           | |
      |           | int
      |           int [n]
a.cc:45:6: error: incompatible types in assignment of 'int' to 'int [n]'
   45 |     s=a[i][2-i];
      |     ~^~~~~~~~~~
a.cc:47:12: error: ordered comparison of pointer with integer zero ('int*' and 'int')
   47 |     while(s>0){
      |           ~^~
a.cc:48:9: error: 'a9' was not declared in this scope; did you mean 'a8'?
   48 |         a9[cnt]=s%10;
      |         ^~
      |         a8
a.cc:48:18: error: invalid operands of types 'int [n]' and 'int' to binary 'operator%'
   48 |         a9[cnt]=s%10;
      |                 ~^~~
      |                 | |
      |                 | int
      |                 int [n]
a.cc:49:12: error: invalid operands of types 'int [n]' and 'int' to binary 'operator/'
   49 |         s=s/10;
      |           ~^~~
      |           | |
      |           | int
      |           int [n]
a.cc:55:12: error: ordered comparison of pointer with integer zero ('int*' and 'int')
   55 |     while(s>0){
      |           ~^~
a.cc:56:15: error: invalid operands of types 'int [n]' and 'int' to binary 'operator%'
   56 |       s[cnt]=s%10;
      |              ~^~~
      |              | |
      |              | int
      |              int [n]
a.cc:57:10: error: invalid operands of types 'int [n]' and 'int' to binary 'operator/'
   57 |       s=s/10;
      |         ~^~~
      |         | |
      |         | int
      |         int [n]