Submission #420959

#TimeUsernameProblemLanguageResultExecution timeMemory
420959marcipan5000Friend (IOI14_friend)C++17
Compilation error
0 ms0 KiB

Compilation message (stderr)

friend.cpp:10:1: error: 'vector' does not name a type
   10 | vector<int> t[15];
      | ^~~~~~
friend.cpp: In function 'void rek(int)':
friend.cpp:17:32: error: 't' was not declared in this scope
   17 |                 for (int j=0;j<t[i].size();j++) {
      |                                ^
friend.cpp:24:13: error: 'max' was not declared in this scope; did you mean 'std::max'?
   24 |         ans=max(ans,w);
      |             ^~~
      |             std::max
In file included from /usr/include/c++/10/vector:60,
                 from friend.cpp:2:
/usr/include/c++/10/bits/stl_algobase.h:300:5: note: 'std::max' declared here
  300 |     max(const _Tp& __a, const _Tp& __b, _Compare __comp)
      |     ^~~
friend.cpp: In function 'int findSample(int, int*, int*, int*)':
friend.cpp:51:16: error: 'max' was not declared in this scope; did you mean 'std::max'?
   51 |             ma=max(ma,confidence[i]);
      |                ^~~
      |                std::max
In file included from /usr/include/c++/10/vector:60,
                 from friend.cpp:2:
/usr/include/c++/10/bits/stl_algobase.h:300:5: note: 'std::max' declared here
  300 |     max(const _Tp& __a, const _Tp& __b, _Compare __comp)
      |     ^~~
friend.cpp:61:16: error: 't' was not declared in this scope
   61 |                t[i].push_back(host[i]);
      |                ^
friend.cpp:65:20: error: 't' was not declared in this scope
   65 |                 uu=t[host[i]].size();
      |                    ^
friend.cpp:72:20: error: 't' was not declared in this scope
   72 |                 uu=t[host[i]].size();
      |                    ^
friend.cpp:95:1: warning: control reaches end of non-void function [-Wreturn-type]
   95 | }
      | ^