/ Vijos /

记录详情

Runtime Error

foo.cpp: In member function 'StringHash::Hash& StringHash::Hash::operator*=(int)':
foo.cpp:39:51: warning: no return statement in function returning non-void [-Wreturn-type]
   inline Hash&operator*=(int x){a*=x;b=(ull)b*x%P;}
                                                   ^
foo.cpp: In member function 'StringHash::Hash& StringHash::Hash::operator*=(const StringHash::Hash&)':
foo.cpp:40:62: warning: no return statement in function returning non-void [-Wreturn-type]
   inline Hash&operator*=(const Hash&x){a*=x.a;b=(ull)b*x.b%P;}
                                                              ^
foo.cpp: In member function 'StringHash::Hash& StringHash::Hash::operator+=(int)':
foo.cpp:41:55: warning: no return statement in function returning non-void [-Wreturn-type]
   inline Hash&operator+=(int x){a+=x;b+=x;b>=P?b-=P:0;}
                                                       ^
foo.cpp: In member function 'StringHash::Hash& StringHash::Hash::operator+=(const StringHash::Hash&)':
foo.cpp:42:66: warning: no return statement in function returning non-void [-Wreturn-type]
   inline Hash&operator+=(const Hash&x){a+=x.a;b+=x.b;b>=P?b-=P:0;}
                                                                  ^
foo.cpp: In constructor 'StringHash::_init_::_init_()':
foo.cpp:50:47: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
  struct _init_{_init_(){po[0]+=1;for(int i=1;i<N;i++)po[i]=po[i-1]*bas;}}_;
                                              ~^~
foo.cpp: In function 'void work(int)':
foo.cpp:120:15: warning: narrowing conversion of 's[x]' from 'char' to 'ull {aka long long unsigned int}' inside { } [-Wnarrowing]
  if((Hash){s[x],s[x]}==fr[1])s1[1%m]++;
            ~~~^
foo.cpp:120:20: warning: narrowing conversion of 's[x]' from 'char' to 'uint {aka unsigned int}' inside { } [-Wnarrowing]
  if((Hash){s[x],s[x]}==fr[1])s1[1%m]++;
                 ~~~^
foo.cpp:124:28: warning: narrowing conversion of 's[x]' from 'char' to 'ull {aka long long unsigned int}' inside { } [-Wnarrowing]
   dfs4(i->to,x,2,(Hash){s[x],s[x]});
                         ~~~^
foo.cpp:124:33: warning: narrowing conversion of 's[x]' from 'char' to 'uint {aka unsigned int}' inside { } [-Wnarrowing]
   dfs4(i->to,x,2,(Hash){s[x],s[x]});
                              ~~~^
# 状态 耗时 内存占用
#1 Runtime Error 31ms 83.906 MiB
#2 Runtime Error 31ms 83.898 MiB
#3 Runtime Error 15ms 83.898 MiB
#4 Runtime Error 31ms 83.902 MiB

信息

递交者
类型
递交
题目
P1995 模式字符串
语言
C++
递交时间
2017-03-02 15:44:16
评测时间
2017-03-02 15:44:16
评测机
分数
0
总耗时
108ms
峰值内存
83.906 MiB