Language: C++

#define _CRT_SECURE_NO_WARNINGS
#define _USE_MATH_DEFINES
??
#include <stdio.h>
#include <ctype.h>
#include <string>
#include <iostream>
#include <vector>
#include <stack>
#include <fstream>
#include <sstream>
#include <queue>
#include <exception>
#include <cmath>
#include <numeric>
??
using namespace std;
typedef long long int lint;
??
bool AOJ0100() {
????????lint n, e, p, q;
????????cin >> n;
????????if (n == 0) return false;
??
????????lint* data = new lint[4001];
????????for (int i = 0; i <= 4000; i++) data[i] = 0;
??
????????for (lint i = 0; i < n; i++) {
????????????????cin >> e >> p >> q;
????????????????data[e] += p * q;
????????}
??
????????bool flag = false;
????????for (int i = 1; i <= 4000; i++) {
????????????????if (data[i] >= 1000000) {
????????????????????????flag = true;
????????????????????????cout << i << endl;
????????????????}
????????}
????????if (!flag) cout << "NA" << endl;
??
????????delete[] data;
????????return true;
}
??
int main()
{
????????while (AOJ0100()) {
????????}
????????return 0;
}

Compiler output:
a.cc:3:1: error: expected unqualified-id before '?' token
    3 | ??
      | ^
In file included from a.cc:5:
/usr/include/ctype.h:81:14: error: '__int32_t' does not name a type; did you mean '__int128_t'?
   81 | extern const __int32_t **__ctype_tolower_loc (void)
      |              ^~~~~~~~~
      |              __int128_t
/usr/include/ctype.h:83:14: error: '__int32_t' does not name a type; did you mean '__int128_t'?
   83 | extern const __int32_t **__ctype_toupper_loc (void)
      |              ^~~~~~~~~
      |              __int128_t
In file included from /usr/include/wchar.h:53,
                 from /usr/include/c++/14/cwchar:44,
                 from /usr/include/c++/14/bits/postypes.h:40,
                 from /usr/include/c++/14/bits/char_traits.h:42,
                 from /usr/include/c++/14/string:42,
                 from a.cc:6:
/usr/include/x86_64-linux-gnu/bits/types/mbstate_t.h:6:9: error: '__mbstate_t' does not name a type
    6 | typedef __mbstate_t mbstate_t;
      |         ^~~~~~~~~~~
/usr/include/wchar.h:104:59: error: 'size_t' has not been declared
  104 |                          const wchar_t *__restrict __src, size_t __n)
      |                                                           ^~~~~~
/usr/include/wchar.h:109:8: error: 'size_t' does not name a type
  109 | extern size_t wcslcpy (wchar_t *__restrict __dest,
      |        ^~~~~~
/usr/include/wchar.h:54:1: note: 'size_t' is defined in header '<cstddef>'; this is probably fixable by adding '#include <cstddef>'
   53 | #include <bits/types/mbstate_t.h>
  +++ |+#include <cstddef>
   54 | #include <bits/types/__FILE.h>
/usr/include/wchar.h:115:8: error: 'size_t' does not name a type
  115 | extern size_t wcslcat (wchar_t *__restrict __dest,
      |        ^~~~~~
/usr/include/wchar.h:115:8: note: 'size_t' is defined in header '<cstddef>'; this is probably fixable by adding '#include <cstddef>'
/usr/include/wchar.h:126:59: error: 'size_t' has not been declared
  126 |                          const wchar_t *__restrict __src, size_t __n)
      |                                                           ^~~~~~
/usr/include/wchar.h:133:63: error: 'size_t' has not been declared
  133 | extern int wcsncmp (const wchar_t *__s1, const wchar_t *__s2, size_t __n)
      |                                                               ^~~~~~
/usr/include/wchar.h:142:25: error: 'size_t' has not been declared
  142 |                         size_t __n) __THROW;
      |                         ^~~~~~
/usr/include/wchar.h:150:27: error: 'size_t' has not been declared
  150 |                           size_t __n, locale_t __loc) __THROW;
      |                           ^~~~~~
/usr/include/wchar.h:159:8: error: 'size_t' does not name a type
  159 | extern size_t wcsxfrm (wchar_t *__restrict __s1,
      |        ^~~~~~
/usr/include/wchar.h:159:8: note: 'size_t' is defined in header '<cstddef>'; this is probably fixable by adding '#include <cstddef>'
/usr/include/wchar.h:174:8: error: 'size_t' does not name a type
  174 | extern size_t wcsxfrm_l (wchar_t *__s1, const wchar_t *__s2,
      |        ^~~~~~
/usr/include/wchar.h:174:8: note: 'size_t' is defined in header '<cstddef>'; this is probably fixable by adding '#include <cstddef>'
/usr/include/wchar.h:212:8: error: 'size_t' does not name a type
  212 | extern size_t wcscspn (const wchar_t *__wcs, const wchar_t *__reject)
      |        ^~~~~~
/usr/include/wchar.h:212:8: note: 'size_t' is defined in header '<cstddef>'; this is probably fixable by adding '#include <cstddef>'
/usr/include/wchar.h:216:8: error: 'size_t' does not name a type
  216 | extern size_t wcsspn (const wchar_t *__wcs, const wchar_t *__accept)
      |        ^~~~~~
/usr/include/wchar.h:216:8: note: 'size_t' is defined in header '<cstddef>'; this is probably fixable by adding '#include <cstddef>'
/usr/include/wchar.h:247:8: error: 'size_t' does not name a type
  247 | extern size_t wcslen (const wchar_t *__s) __THROW __attribute_pure__;
      |        ^~~~~~
/usr/include/wchar.h:247:8: note: 'size_t' is defined in header '<cstddef>'; this is probably fixable by adding '#include <cstddef>'
/usr/include/wchar.h:265:8: error: 'size_t' does not name a type
  265 | extern size_t wcsnlen (const wchar_t *__s, size_t __maxlen)
      |        ^~~~~~
/usr/include/wchar.h:265:8: note: 'size_t' is defined in header '<cstddef>'; this is probably fixable by adding '#include <cstddef>'
/usr/include/wchar.h:272:59: error: 'size_t' has not been declared
  272 | extern "C++" wchar_t *wmemchr (wchar_t *__s, wchar_t __c, size_t __n)
      |                                                           ^~~~~~
/usr/include/wchar.h:275:38: error: 'size_t' has not been declared
  275 |                                      size_t __n)
      |                                      ^~~~~~
/usr/include/wchar.h:283:63: error: 'size_t' has not been declared
  283 | extern int wmemcmp (const wchar_t *__s1, const wchar_t *__s2, size_t __n)
      |                                                               ^~~~~~
/usr/include/wchar.h:288:58: error: 'size_t' has not been declared
  288 |                          const wchar_t *__restrict __s2, size_t __n) __THROW;
      |                                                          ^~~~~~
/usr/include/wchar.h:292:63: error: 'size_t' has not been declared
  292 | extern wchar_t *wmemmove (wchar_t *__s1, const wchar_t *__s2, size_t __n)
      |                                                               ^~~~~~
/usr/include/wchar.h:296:53: error: 'size_t' has not been declared
  296 | extern wchar_t *wmemset (wchar_t *__s, wchar_t __c, size_t __n) __THROW;
      |                                                     ^~~~~~
/usr/include/wchar.h:302:59: error: 'size_t' has not been declared
  302 |                           const wchar_t *__restrict __s2, size_t __n)
      |                                                           ^~~~~~
/usr/include/wchar.h:317:27: error: 'mbstate_t' does not name a type
  317 | extern int mbsinit (const mbstate_t *__ps) __THROW __attribute_pure__;
      |                           ^~~~~~~~~
/usr/include/wchar.h:321:8: error: 'size_t' does not name a type
  321 | extern size_t mbrtowc (wchar_t *__restrict __pwc,
      |        ^~~~~~
/usr/include/wchar.h:321:8: note: 'size_t' is defined in header '<cstddef>'; this is probably fixable by adding '#include <cstddef>'
/usr/include/wchar.h:326:8: error: 'size_t' does not name a type
  326 | extern size_t wcrtomb (char *__restrict __s, wchar_t __wc,
      |        ^~~~~~
/usr/include/wchar.h:326:8: note: 'size_t' is defined in header '<cstddef>'; this is probably fixable by adding '#include <cstddef>'
/usr/include/wchar.h:330:8: error: 'size_t' does not name a type
  330 | extern size_t __mbrlen (const char *__restrict __s, size_t __n,
      |        ^~~~~~
/usr/include/wchar.h:330:8: note: 'size_t' is defined in header '<cstddef>'; this is probably fixable by adding '#include <cstddef>'
/usr/include/wchar.h:332:8: error: 'size_t' does not name a type
  332 | extern size_t mbrlen (const char *__restrict __s, size_t __n,
      |        ^~~~~~
/usr/include/wchar.h:332:8: note: 'size_t' is defined in header '<cstddef>'; this is probably fixable by adding '#include <cstddef>'
/usr/include/wchar.h:362:8: error: 'size_t' does not name a type
  362 | extern size_t mbsrtowcs (wchar_t *__restrict __dst,
      |        ^~~~~~
/usr/include/wchar.h:362:8: note: 'size_t' is defined in header '<cstddef>'; this is probably fixable by adding '#include <cstddef>'
/usr/include/wchar.h:368:8: error: 'size_t' does not name a type
  368 | extern size_t wcsrtombs (char *__restrict __dst,
      |        ^~~~~~
/usr/include/wchar.h:368:8: note: 'size_t' is defined in header '<cstddef>'; this is probably fixable by adding '#include <cstddef>'
/usr/include/wchar.h:376:8: error: 'size_t' does not name a type
  376 | extern size_t mbsnrtowcs (wchar_t *__restrict __dst,
      |        ^~~~~~
/usr/include/wchar.h:376:8: note: 'size_t' is defined in header '<cstddef>'; this is probably fixable by adding '#include <cstddef>'
/usr/include/wchar.h:382:8: error: 'size_t' does not name a type
  382 | extern size_t wcsnrtombs (char *__restrict __dst,
      |        ^~~~~~
/usr/include/wchar.h:382:8: note: 'size_t' is defined in header '<cstddef>'; this is probably fixable by adding '#include <cstddef>'
/usr/include/wchar.h:396:42: error: 'size_t' has not been declared
  396 | extern int wcswidth (const wchar_t *__s, size_t __n) __THROW;
      |                                          ^~~~~~
/usr/include/wchar.h:695:59: error: 'size_t' has not been declared
  695 |                          const wchar_t *__restrict __src, size_t __n)
      |                                                           ^~~~~~
/usr/include/wchar.h:718:8: error: '__FILE' does not name a type; did you mean 'EMFILE'?
  718 | extern __FILE *open_wmemstream (wchar_t **__bufloc, size_t *__sizeloc) __THROW
      |        ^~~~~~
      |        EMFILE
/usr/include/wchar.h:725:19: error: '__FILE' was not declared in this scope; did you mean 'EMFILE'?
  725 | extern int fwide (__FILE *__fp, int __mode) __THROW;
      |                   ^~~~~~
      |                   EMFILE
/usr/include/wchar.h:725:27: error: '__fp' was not declared in this scope
  725 | extern int fwide (__FILE *__fp, int __mode) __THROW;
      |                           ^~~~
/usr/include/wchar.h:725:33: error: expected primary-expression before 'int'
  725 | extern int fwide (__FILE *__fp, int __mode) __THROW;
      |                                 ^~~
/usr/include/wchar.h:725:43: error: expression list treated as compound expression in initializer [-fpermissive]
  725 | extern int fwide (__FILE *__fp, int __mode) __THROW;
      |                                           ^
/usr/include/wchar.h:732:22: error: '__FILE' was not declared in this scope; did you mean 'EMFILE'?
  732 | extern int fwprintf (__FILE *__restrict __stream,
      |                      ^~~~~~
      |                      EMFILE
/usr/include/wchar.h:732:30: error: expected primary-expression before '__restrict'
  732 | extern int fwprintf (__FILE *__restrict __stream,
      |