正文
增加 2 行删除 2 行
1234557 行未改动63646566676869707123 行未改动[](https://www.luogu.com.cn/problem/P4691) [](https://www.luogu.com.cn/problem/P3934)哈哈哈哈双倍经验可以写题解笑死我了哈哈哈哈。谨以此题解,纪念我的第一道 Ynoi。57 行未改动int p=phi[mod];pair<int,bool> t=dfs(now+1,p);flag=1;int tt=get_sum(now);if(tt>=mod) flag=0,tt%=mod;int ans=qpow(tt,t.first+(t.second?0:p),mod);return {ans,flag};}signed main(){23 行未改动1234557 行未改动63646566676869707123 行未改动[](https://www.luogu.com.cn/problem/P4691) [](https://www.luogu.com.cn/problem/P3934)哈哈哈哈双倍经验可以写题解笑死我了哈哈哈哈。谨以此题解,纪念我的第一道 Ynoi。57 行未改动int p=phi[mod];pair<int,bool> t=dfs(now+1,p);flag=1;int tt=get_sum(now);if(tt>=mod) flag=0,tt%=mod;int ans=qpow(tt,t.first+(t.second?0:p),mod);return {ans,flag};}signed main(){23 行未改动