这道题略微卡常,手写个哈希表吧,不要用 map
by CodingJellyfish @ 2021-12-22 14:43:24
@[Remained_Apple](/user/182533) 你可以到这里来交一下
https://www.luogu.com.cn/problem/U195241
by RainFestival @ 2021-12-22 15:11:18
@[Remained_Apple](/user/182533) map+O2可过,这题卡了unorder_map。~~(顺便膜拜手写hash表的大神)~~
by peiwenjun @ 2021-12-22 15:14:57
https://www.luogu.com.cn/record/65559597 尽我所能了,卡到 1.59 s,剩下的您自己来吧
by CodingJellyfish @ 2021-12-22 15:16:49
@[Remained_Apple](/user/182533)
```
re ll x = b * qpow(a, i, p) % p;
```
这里 **不要** 对于每一个 i 都做快速幂
by RainFestival @ 2021-12-22 15:20:42
@[RainFestival](/user/36957) 改成递推地做
by RainFestival @ 2021-12-22 15:20:56
@[RainFestival](/user/36957) 还是过不了,我试了
by CodingJellyfish @ 2021-12-22 15:22:06
@[DoctorJellyfish](/user/52381) https://www.luogu.com.cn/record/65559942
by RainFestival @ 2021-12-22 15:23:11
@[DoctorJellyfish](/user/52381) ~~你脸黑罢~~
by RainFestival @ 2021-12-22 15:23:27
@[RainFestival](/user/36957) 害我多交一遍。。
by RainFestival @ 2021-12-22 15:23:45