QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#654533#9313. Make MaxZhaoZiLongCompile Error//C++981.1kb2024-10-18 21:44:442024-10-18 21:44:45

詳細信息

answer.code: In function ‘void solution()’:
answer.code:13:20: error: ISO C++ forbids declaration of ‘it’ with no type [-fpermissive]
   13 |         for (auto &it : a)cin >> it;
      |                    ^~
answer.code:13:25: warning: range-based ‘for’ loops only available with ‘-std=c++11’ or ‘-std=gnu++11’ [-Wc++11-extensions]
   13 |         for (auto &it : a)cin >> it;
      |                         ^
answer.code:13:25: error: forming reference to reference type ‘std::vector<int>&’
answer.code:16:28: error: ‘>>’ should be ‘> >’ within a nested template argument list
   16 |         stack<pair<int, int>>st, stt;
      |                            ^~
      |                            > >
answer.code:24:25: warning: extended initializer lists only available with ‘-std=c++11’ or ‘-std=gnu++11’ [-Wc++11-extensions]
   24 |                 st.push({a[i], i});
      |                         ^
answer.code:24:24: warning: extended initializer lists only available with ‘-std=c++11’ or ‘-std=gnu++11’ [-Wc++11-extensions]
   24 |                 st.push({a[i], i});
      |                 ~~~~~~~^~~~~~~~~~~
answer.code:34:26: warning: extended initializer lists only available with ‘-std=c++11’ or ‘-std=gnu++11’ [-Wc++11-extensions]
   34 |                 stt.push({a[i], i});
      |                          ^
answer.code:34:25: warning: extended initializer lists only available with ‘-std=c++11’ or ‘-std=gnu++11’ [-Wc++11-extensions]
   34 |                 stt.push({a[i], i});
      |                 ~~~~~~~~^~~~~~~~~~~