| Run ID | Author | Problem | Lang | Verdict | Score | Time | Memory | Code Length | Submit Time |
|---|---|---|---|---|---|---|---|---|---|
| 54411 | 张弛 | 国王的米粒 | C++ | Accepted | 100 | 0 MS | 252 KB | 235 | 2022-07-29 15:19:45 |
#include<bits/stdc++.h> using namespace std; long long m,n,ans,c=1; int main(){ cin>>m>>n; if(m>n) swap(m,n); for(int i=1;i<m;i++){ c*=2; } for(int i=0;i<=n-m;i++){ ans+=c; c*=2; } cout<<ans; return 0; }