水题
#include<bits/stdc++.h> using namespace std; int a, b, k; int main(){ cin >> a >> b >> k; while(k--) if(a>b) a /= 2; else b /= 2; cout << max(a,b) << " " << min(a,b) << endl; return 0; }
2024-03-15 14:26:53
水题
#include<bits/stdc++.h> using namespace std; int a, b, k; int main(){ cin >> a >> b >> k; while(k--) if(a>b) a /= 2; else b /= 2; cout << max(a,b) << " " << min(a,b) << endl; return 0; }