/ Vijos /

记录详情

Compile Error

foo.cpp: In member function 'void Bignum::Check()':
foo.cpp:22:29: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
   for(int i = 1; i < v.size(); i++) {
                             ^
foo.cpp: In member function 'Bignum& Bignum::operator*=(int)':
foo.cpp:33:29: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
   for(int i = 0; i < v.size(); i++) {
                             ^
foo.cpp: In function 'int main()':
foo.cpp:72:12: error: 'People' was not declared in this scope
     vector<People> v(1);
            ^
foo.cpp:72:18: error: template argument 1 is invalid
     vector<People> v(1);
                  ^
foo.cpp:72:18: error: template argument 2 is invalid
foo.cpp:72:21: error: invalid type in declaration before '(' token
     vector<People> v(1);
                     ^
foo.cpp:74:5: error: 'Wint' was not declared in this scope
     Wint s=1,ans=0;
     ^
foo.cpp:74:10: error: expected ';' before 's'
     Wint s=1,ans=0;
          ^
foo.cpp:75:15: error: request for member 'back' in 'v', which is of non-class type 'int'
     cin>>n>>v.back().a>>v.back().b;
               ^
foo.cpp:75:27: error: request for member 'back' in 'v', which is of non-class type 'int'
     cin>>n>>v.back().a>>v.back().b;
                           ^
foo.cpp:78:11: error: request for member 'push_back' in 'v', which is of non-class type 'int'
         v.push_back(v.front());
           ^
foo.cpp:78:23: error: request for member 'front' in 'v', which is of non-class type 'int'
         v.push_back(v.front());
                       ^
foo.cpp:79:16: error: request for member 'back' in 'v', which is of non-class type 'int'
         cin>>v.back().a>>v.back().b;
                ^
foo.cpp:79:28: error: request for member 'back' in 'v', which is of non-class type 'int'
         cin>>v.back().a>>v.back().b;
                            ^
foo.cpp:81:12: error: request for member 'begin' in 'v', which is of non-class type 'int'
     sort(v.begin()+1,v.end());
            ^
foo.cpp:81:24: error: request for member 'end' in 'v', which is of non-class type 'int'
     sort(v.begin()+1,v.end());
                        ^
foo.cpp:82:23: error: request for member 'size' in 'v', which is of non-class type 'int'
     for(int i=1; i!=v.size(); ++i)
                       ^
foo.cpp:84:9: error: 's' was not declared in this scope
         s*=v[i-1].a;
         ^
foo.cpp:84:17: error: invalid types 'int[int]' for array subscript
         s*=v[i-1].a;
                 ^
foo.cpp:85:9: error: 'ans' was not declared in this scope
         ans=max(ans,s/v[i].b);
         ^
foo.cpp:85:26: error: invalid types 'int[int]' for array subscript
         ans=max(ans,s/v[i].b);
                          ^
foo.cpp:87:11: error: 'ans' was not declared in this scope
     cout<<ans;
           ^

信息

递交者
类型
递交
题目
P1779 国王游戏
语言
C++
递交时间
2016-11-18 00:17:17
评测时间
2016-11-18 00:17:18
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes