记录详情

Compile Error

/in/foo.cc: In function 'void Change()':
/in/foo.cc:21:6: error: 'i' was not declared in this scope
  for(i=t;i<t+z2;i++)
      ^
/in/foo.cc:27:11: error: reference to 'max' is ambiguous
  if(count>max) max=count;
           ^~~
/in/foo.cc:6:5: note: candidates are: int max
 int max=0; int n;
     ^~~
In file included from /usr/include/c++/6/bits/char_traits.h:39:0,
                 from /usr/include/c++/6/ios:40,
                 from /usr/include/c++/6/ostream:38,
                 from /usr/include/c++/6/iostream:39,
                 from /in/foo.cc:1:
/usr/include/c++/6/bits/stl_algobase.h:265:5: note:                 template<class _Tp, class _Compare> const _Tp& std::max(const _Tp&, const _Tp&, _Compare)
     max(const _Tp& __a, const _Tp& __b, _Compare __comp)
     ^~~
/usr/include/c++/6/bits/stl_algobase.h:219:5: note:                 template<class _Tp> const _Tp& std::max(const _Tp&, const _Tp&)
     max(const _Tp& __a, const _Tp& __b)
     ^~~
/in/foo.cc:27:16: error: reference to 'max' is ambiguous
  if(count>max) max=count;
                ^~~
/in/foo.cc:6:5: note: candidates are: int max
 int max=0; int n;
     ^~~
In file included from /usr/include/c++/6/bits/char_traits.h:39:0,
                 from /usr/include/c++/6/ios:40,
                 from /usr/include/c++/6/ostream:38,
                 from /usr/include/c++/6/iostream:39,
                 from /in/foo.cc:1:
/usr/include/c++/6/bits/stl_algobase.h:265:5: note:                 template<class _Tp, class _Compare> const _Tp& std::max(const _Tp&, const _Tp&, _Compare)
     max(const _Tp& __a, const _Tp& __b, _Compare __comp)
     ^~~
/usr/include/c++/6/bits/stl_algobase.h:219:5: note:                 template<class _Tp> const _Tp& std::max(const _Tp&, const _Tp&)
     max(const _Tp& __a, const _Tp& __b)
     ^~~
/in/foo.cc:30:6: error: 'i' was not declared in this scope
  for(i=0;i<t;i++)
      ^
/in/foo.cc: In function 'int main()':
/in/foo.cc:45:8: error: reference to 'max' is ambiguous
  cout<<max;
        ^~~
/in/foo.cc:6:5: note: candidates are: int max
 int max=0; int n;
     ^~~
In file included from /usr/include/c++/6/bits/char_traits.h:39:0,
                 from /usr/include/c++/6/ios:40,
                 from /usr/include/c++/6/ostream:38,
                 from /usr/include/c++/6/iostream:39,
                 from /in/foo.cc:1:
/usr/include/c++/6/bits/stl_algobase.h:265:5: note:                 template<class _Tp, class _Compare> const _Tp& std::max(const _Tp&, const _Tp&, _Compare)
     max(const _Tp& __a, const _Tp& __b, _Compare __comp)
     ^~~
/usr/include/c++/6/bits/stl_algobase.h:219:5: note:                 template<class _Tp> const _Tp& std::max(const _Tp&, const _Tp&)
     max(const _Tp& __a, const _Tp& __b)
     ^~~

信息

递交者
类型
递交
题目
P1190 斯芬克斯
比赛
2020年互联网创新创业科技节程序设计大赛
语言
C++
递交时间
2020-12-09 16:55:58
评测时间
2020-12-09 16:55:58
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes