Run ID | Author | Problem | Lang | Verdict | Score | Time | Memory | Code Length | Submit Time |
---|---|---|---|---|---|---|---|---|---|
67852 | MattL | 集合 | C++ | Wrong Answer | 90 | 0 MS | 248 KB | 277 | 2023-01-20 02:18:03 |
#include<bits/stdc++.h> using namespace std; long long n,k,p,m,ans=1; int main() { // freopen("set.in","r",stdin); // freopen("set.out","w",stdout); cin>>n>>k>>p; m=log(n)/log(k); for(int i=0;i<=m;i++) ans*=k; cout<<(ans-k)/(k-1)+(p-m)*n; return 0; }