fork download
  1. #include <iostream>
  2.  
  3. using namespace std;
  4.  
  5. int main() {
  6. long long a, b;
  7. cin >> a >> b;
  8. cout << min((a+b)/3, min(a,b));
  9.  
  10. return 0;
  11. }
Success #stdin #stdout 0s 4392KB
stdin
Standard input is empty
stdout
Standard output is empty