QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#787969 | #5. 在线 O(1) 逆元 | dinnerWu | 0 | 0ms | 0kb | C++14 | 193b | 2024-11-27 15:25:46 | 2024-11-27 15:25:47 |
answer
#import"inv.h"
const int m=998244353;int f[200000000],i=f[1]=1;void init(int p){for(;++i<2e8;f[i]=(long long)(m-m/i)*f[m%i]%m);}int inv(int x){return x<2e8?f[x]:(long long)(m-m/x)*inv(m%x)%m;}
Details
Pretests
Final Tests
Test #1:
score: 0
Memory Limit Exceeded
Test #2:
score: 0
Memory Limit Exceeded
Test #3:
score: 0
Memory Limit Exceeded
Test #4:
score: 0
Memory Limit Exceeded
Test #5:
score: 0
Memory Limit Exceeded