/ Vijos /

记录详情

Compile Error

/in/foo.cc: In function 'void p1005()':
/in/foo.cc:10:31: error: 'memset' was not declared in this scope
     memset(next,0,sizeof(next));
                               ^
/in/foo.cc:12:22: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
     for(int i=1,k=0;i<str.size();){
                     ~^~~~~~~~~~~
/in/foo.cc:25:5: error: 'LL' was not declared in this scope
     LL num = 0;
     ^~
/in/foo.cc:26:5: error: 'stack' is not a member of 'std'
     std::stack<int>st;
     ^~~
/in/foo.cc:26:16: error: expected primary-expression before 'int'
     std::stack<int>st;
                ^~~
/in/foo.cc:27:18: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
     for(int k=0;k<str.size();){
                 ~^~~~~~~~~~~
/in/foo.cc:28:12: error: expected ';' before 't'
         LL t = ++num;
            ^
/in/foo.cc:29:15: error: 't' was not declared in this scope
         while(t){
               ^
/in/foo.cc:30:13: error: 'st' was not declared in this scope
             st.push(t%10);
             ^~
/in/foo.cc:33:16: error: 'st' was not declared in this scope
         while(!st.empty()&&k<str.size()){
                ^~
/in/foo.cc:33:29: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
         while(!st.empty()&&k<str.size()){
                            ~^~~~~~~~~~~

信息

递交者
类型
递交
题目
P1005 超长数字串
语言
C++
递交时间
2020-04-19 12:45:54
评测时间
2020-04-19 12:45:54
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes