Language: C++

#include <iostream>
using namespace std;
int main ()
{
????????int i;
????????cin >> i;
????????int a[i];
????????for (int j=0;j<i;j++)
????????{
????????????????cin >> a[j];
????????}
????????for (int k=i-1;k>=1;k--)
????????{
????????????????cout << a[k] << " ";
????????}
cout << a[0];
????????return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:1: error: expected primary-expression before '?' token
    5 | ????????int i;
      | ^
a.cc:5:2: error: expected primary-expression before '?' token
    5 | ????????int i;
      |  ^
a.cc:5:3: error: expected primary-expression before '?' token
    5 | ????????int i;
      |   ^
a.cc:5:4: error: expected primary-expression before '?' token
    5 | ????????int i;
      |    ^
a.cc:5:5: error: expected primary-expression before '?' token
    5 | ????????int i;
      |     ^
a.cc:5:6: error: expected primary-expression before '?' token
    5 | ????????int i;
      |      ^
a.cc:5:7: error: expected primary-expression before '?' token
    5 | ????????int i;
      |       ^
a.cc:5:8: error: expected primary-expression before '?' token
    5 | ????????int i;
      |        ^
a.cc:5:9: error: expected primary-expression before 'int'
    5 | ????????int i;
      |         ^~~
a.cc:5:9: error: expected ':' before 'int'
    5 | ????????int i;
      |         ^~~
      |         :
a.cc:5:9: error: expected primary-expression before 'int'
    5 | ????????int i;
      |         ^~~
a.cc:5:9: error: expected ':' before 'int'
    5 | ????????int i;
      |         ^~~
      |         :
a.cc:5:9: error: expected primary-expression before 'int'
    5 | ????????int i;
      |         ^~~
a.cc:5:9: error: expected ':' before 'int'
    5 | ????????int i;
      |         ^~~
      |         :
a.cc:5:9: error: expected primary-expression before 'int'
    5 | ????????int i;
      |         ^~~
a.cc:5:9: error: expected ':' before 'int'
    5 | ????????int i;
      |         ^~~
      |         :
a.cc:5:9: error: expected primary-expression before 'int'
    5 | ????????int i;
      |         ^~~
a.cc:5:9: error: expected ':' before 'int'
    5 | ????????int i;
      |         ^~~
      |         :
a.cc:5:9: error: expected primary-expression before 'int'
    5 | ????????int i;
      |         ^~~
a.cc:5:9: error: expected ':' before 'int'
    5 | ????????int i;
      |         ^~~
      |         :
a.cc:5:9: error: expected primary-expression before 'int'
    5 | ????????int i;
      |         ^~~
a.cc:5:9: error: expected ':' before 'int'
    5 | ????????int i;
      |         ^~~
      |         :
a.cc:5:9: error: expected primary-expression before 'int'
    5 | ????????int i;
      |         ^~~
a.cc:5:9: error: expected ':' before 'int'
    5 | ????????int i;
      |         ^~~
      |         :
a.cc:5:9: error: expected primary-expression before 'int'
    5 | ????????int i;
      |         ^~~
a.cc:6:1: error: expected primary-expression before '?' token
    6 | ????????cin >> i;
      | ^
a.cc:6:2: error: expected primary-expression before '?' token
    6 | ????????cin >> i;
      |  ^
a.cc:6:3: error: expected primary-expression before '?' token
    6 | ????????cin >> i;
      |   ^
a.cc:6:4: error: expected primary-expression before '?' token
    6 | ????????cin >> i;
      |    ^
a.cc:6:5: error: expected primary-expression before '?' token
    6 | ????????cin >> i;
      |     ^
a.cc:6:6: error: expected primary-expression before '?' token
    6 | ????????cin >> i;
      |      ^
a.cc:6:7: error: expected primary-expression before '?' token
    6 | ????????cin >> i;
      |       ^
a.cc:6:8: error: expected primary-expression before '?' token
    6 | ????????cin >> i;
      |        ^
a.cc:6:16: error: 'i' was not declared in this scope
    6 | ????????cin >> i;
      |                ^
a.cc:6:17: error: expected ':' before ';' token
    6 | ????????cin >> i;
      |                 ^
      |                 :
a.cc:6:17: error: expected primary-expression before ';' token
a.cc:6:17: error: expected ':' before ';' token
    6 | ????????cin >> i;
      |                 ^
      |                 :
a.cc:6:17: error: expected primary-expression before ';' token
a.cc:6:17: error: expected ':' before ';' token
    6 | ????????cin >> i;
      |                 ^
      |                 :
a.cc:6:17: error: expected primary-expression before ';' token
a.cc:6:17: error: expected ':' before ';' token
    6 | ????????cin >> i;
      |                 ^
      |                 :
a.cc:6:17: error: expected primary-expression before ';' token
a.cc:6:17: error: expected ':' before ';' token
    6 | ????????cin >> i;
      |                 ^
      |                 :
a.cc:6:17: error: expected primary-expression before ';' token
a.cc:6:17: error: expected ':' before ';' token
    6 | ????????cin >> i;
      |                 ^
      |                 :
a.cc:6:17: error: expected primary-expression before ';' token
a.cc:6:17: error: expected ':' before ';' token
    6 | ????????cin >> i;
      |                 ^
      |                 :
a.cc:6:17: error: expected primary-expression before ';' token
a.cc:6:17: error: expected ':' before ';' token
    6 | ????????cin >> i;
      |                 ^
      |                 :
a.cc:6:17: error: expected primary-expression before ';' token
a.cc:7:1: error: expected primary-expression before '?' token
    7 | ????????int a[i];
      | ^
a.cc:7:2: error: expected primary-expression before '?' token
    7 | ????????int a[i];
      |  ^
a.cc:7:3: error: expected primary-expression before '?' token
    7 | ????????int a[i];
      |   ^
a.cc:7:4: error: expected primary-expression before '?' token
    7 | ????????int a[i];
      |    ^
a.cc:7:5: error: expected primary-expression before '?' token
    7 | ????????int a[i];
      |     ^
a.cc:7:6: error: expected primary-expression before '?' token
    7 | ????????int a[i];
      |      ^
a.cc:7:7: error: expected primary-expression before '?' token
    7 | ????????int a[i];
      |       ^
a.cc:7:8: error: expected primary-expression before '?' token
    7 | ????????int a[i];
      |        ^
a.cc:7:9: error: expected primary-expression before 'int'
    7 | ????????int a[i];
      |         ^~~
a.cc:7:9: error: expected ':' before 'int'
    7 | ????????int a[i];
      |         ^~~
      |         :
a.cc:7:9: error: expected primary-expression before 'int'
    7 | ????????int a[i];
      |         ^~~
a.cc:7:9: error: expected ':' before 'int'
    7 | ????????int a[i];
      |         ^~~
      |         :
a.cc:7:9: error: expected primary-expression before 'int'
    7 | ????????int a[i];
      |         ^~~
a.cc:7:9: error: expected ':' before 'int'
    7 | ????????int a[i];
      |         ^~~
      |         :
a.cc:7:9: error: expected primary-expression before 'int'
    7 | ????????int a[i];
      |         ^~~
a.cc:7:9: error: expected ':' before 'int'
    7 | ????????int a[i];
      |         ^~~
      |         :
a.cc:7:9: error: expected primary-expression before 'int'
    7 | ????????int a[i];
      |         ^~~
a.cc:7:9: error: expected ':' before 'int'
    7 | ????????int a[i];
      |         ^~~
      |         :
a.cc:7:9: error: expected primary-expression before 'int'
    7 | ????????int a[i];
      |         ^~~
a.cc:7:9: error: expected ':' before 'int'
    7 | ????????int a[i];
      |         ^~~
      |         :
a.cc:7:9: error: expected primary-expression before 'int'
    7 | ????????int a[i];
      |         ^~~
a.cc:7:9: error: expected ':' before 'int'
    7 | ????????int a[i];
      |         ^~~
      |         :
a.cc:7:9: error: expected primary-expression before 'int'
    7 | ????????int a[i];
      |         ^~~
a.cc:7:9: error: expected ':' before 'int'
    7 | ????????int a[i];
      |         ^~~
      |         :
a.cc:7:9: error: expected primary-expression before 'int'
    7 | ????????int a[i];
      |         ^~~
a.cc:8:1: error: expected primary-expression before '?' token
    8 | ????????for (int j=0;j<i;j++)
      | ^
a.cc:8:2: error: expected primary-expression before '?' token
    8 | ????????for (int j=0;j<i;j++)
      |  ^
a.cc:8:3: error: expected primary-expression before '?' token
    8 | ????????for (int j=0;j<i;j++)
      |   ^
a.cc:8:4: error: expected primary-expression before '?' token
    8 | ????????for (int j=0;j<i;j++)
      |    ^
a.cc:8:5: error: expected primary-expression before '?' token
    8 | ????????for (int j=0;j<i;j++)
      |     ^
a.cc:8:6: error: expected primary-expression before '?' token
    8 | ????????for (int j=0;j<i;j++)
      |      ^
a.cc:8:7: error: expected primary-expression before '?' token
    8 | ????????for (int j=0;j<i;j++)
      |       ^
a.cc:8:8: error: expected primary-expression before '?' token
    8 | ????????for (int j=0;j<i;j++)
      |        ^
a.cc:8:9: error: expected primary-expression before 'for'
    8 | ????????for (int j=0;j<i;j++)
      |         ^~~
a.cc:8:9: error: expected ':' before 'for'
    8 | ????????for (int j=0;j<i;j++)
      |         ^~~
      |         :
a.cc:8:9: error: expected primary-expression before 'for'
    8 | ????????for (int j=0;j<i;j++)
      |         ^~~
a.cc:8:9: error: expected ':' before 'for'
    8 | ????????for (int j=0;j<i;j++)
      |         ^~~
      |         :
a.cc:8:9: error: expected primary-expression before 'for'
    8 | ????????for (int j=0;j<i;j++)
      |         ^~~
a.cc:8:9: error: expected ':' before 'for'
    8 | ????????for (int j=0;j<i;j++)
      |         ^~~
      |         :
a.cc:8:9: error: expected primary-expression before 'for'
    8 | ????????for (int j=0;j<i;j++)
      |         ^~~
a.cc:8:9: error: expected ':' before 'for'
    8 | ????????for (int j=0;j<i;j++)
      |         ^~~
      |         :
a.cc:8:9: error: expected primary-expression before 'for'
    8 | ????????for (int j=0;j<i;j++)
      |         ^~~
a.cc:8:9: error: expected ':' before 'for'
    8 | ????????for (int j=0;j<i;j++)
      |         ^~~
      |         :
a.cc:8:9: error: expected primary-expression before 'for'
    8 | ????????for (int j=0;j<i;j++)
      |         ^~~
a.cc:8:9: error: expected ':' before 'for'
    8 | ????????for (int j=0;j<i;j++)
      |         ^~~
      |         :
a.cc:8:9: error: expected primary-expression before 'for'
    8 | ????????for (int j=0;j<i;j++)
      |         ^~~
a.cc:8:9: error: expected ':' before 'for'
    8 | ????????for (int j=0;j<i;j++)
      |         ^~~
      |         :
a.cc:8:9: error: expected primary-expression before 'for'
    8 | ????????for (int j=0;j<i;j++)