Language: C++

#include <bits/stdc++.h>
struct Edge {
  ll to;
  ll cost;
};
const ll mx = 1e18;
int main() {
  int N;
  cin >> N;
  vector<ll> A(N);
  REP(i, N) {
    cin >> A[i];
    if (A[i] == 0) {
      cout << 0 << endl;
      return 0;
    }
  }
  ll ans = 1;
  REP(i,N){
    if(mx/A[i]<ans){
      cout << -1 << endl;
      return 0;
    }
    ans *= A[i];
  }
  cout << ans << endl;
}

Compiler output:
a.cc:3:3: error: 'll' does not name a type
    3 |   ll to;
      |   ^~
a.cc:4:3: error: 'll' does not name a type
    4 |   ll cost;
      |   ^~
a.cc:6:7: error: 'll' does not name a type
    6 | const ll mx = 1e18;
      |       ^~
a.cc: In function 'int main()':
a.cc:9:3: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    9 |   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:10:3: error: 'vector' was not declared in this scope
   10 |   vector<ll> A(N);
      |   ^~~~~~
a.cc:10:3: note: suggested alternatives:
In file included from /usr/include/c++/14/vector:66,
                 from /usr/include/c++/14/functional:64,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:53:
/usr/include/c++/14/bits/stl_vector.h:428:11: note:   'std::vector'
  428 |     class vector : protected _Vector_base<_Tp, _Alloc>
      |           ^~~~~~
/usr/include/c++/14/vector:93:13: note:   'std::pmr::vector'
   93 |       using vector = std::vector<_Tp, polymorphic_allocator<_Tp>>;
      |             ^~~~~~
a.cc:10:10: error: 'll' was not declared in this scope
   10 |   vector<ll> A(N);
      |          ^~
a.cc:10:14: error: 'A' was not declared in this scope
   10 |   vector<ll> A(N);
      |              ^
a.cc:11:7: error: 'i' was not declared in this scope
   11 |   REP(i, N) {
      |       ^
a.cc:11:3: error: 'REP' was not declared in this scope
   11 |   REP(i, N) {
      |   ^~~
a.cc:18:5: error: expected ';' before 'ans'
   18 |   ll ans = 1;
      |     ^~~~
      |     ;
a.cc:26:3: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   26 |   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:26:11: error: 'ans' was not declared in this scope; did you mean 'abs'?
   26 |   cout << ans << endl;
      |           ^~~
      |           abs
a.cc:26:18: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   26 |   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)
      |     ^~~~