TheMagnusRex

pavlova4.4

Jan 14th, 2021
454
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. using namespace std;
  2.  
  3. #include <iostream>
  4.  
  5. int main() {
  6.     double m,n;
  7.     cout<<"m=";
  8.     cin>>m;
  9.     cout<<"n=";
  10.     cin>>n;
  11.     if(m<n){
  12.         n=2*m*n;
  13.         m=m/2;
  14.         cout<<"m="<<m<<" n="<<n;
  15.     }
  16.     else{
  17.         m=2*m*n;
  18.         n=n/2;
  19.         cout<<"m="<<m<<" n="<<n;
  20.     }
  21.     return 0;
  22. }
RAW Paste Data