/ Vijos /

记录详情

Compile Error

/in/foo.cc: In function 'LL ksm(LL, LL)':
/in/foo.cc:3:46: error: 'mod' was not declared in this scope; did you mean 'modf'?
    3 | inline LL ksm(LL a,LL b){LL r=1;for(;b;a=a*a%mod,b>>=1)if(b&1)r=r*a%mod;return r;}
      |                                              ^~~
      |                                              modf
/in/foo.cc: In function 'int main()':
/in/foo.cc:12:44: error: 'mod' was not declared in this scope; did you mean 'modf'?
   12 |                 printf("%lld",4*ksm(3,m-1)%mod);
      |                                            ^~~
      |                                            modf
/in/foo.cc:14:46: error: 'mod' was not declared in this scope; did you mean 'modf'?
   14 |                 printf("%lld",112*ksm(3,m-3)%mod);
      |                                              ^~~
      |                                              modf
/in/foo.cc:18:52: error: 'mod' was not declared in this scope; did you mean 'modf'?
   18 |                         printf("%lld",(83*ksm(8,n)%mod+5*ksm(2,n+7)%mod)*190104168%mod);
      |                                                    ^~~
      |                                                    modf
/in/foo.cc:20:52: error: 'mod' was not declared in this scope; did you mean 'modf'?
   20 |                         printf("%lld",(83*ksm(8,n)%mod+ksm(2,n+8))*ksm(3,m-n-1)%mod*570312504%mod);
      |                                                    ^~~
      |                                                    modf

信息

递交者
类型
递交
题目
P2062 填数游戏
语言
C++
递交时间
2025-12-26 20:16:46
评测时间
2025-12-26 20:16:46
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes