SHARE
TWEET

| = | = | = | = | = |

daniil_mironoff Jun 17th, 2019 71 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. using namespace std;
  2.  
  3. int const SIZE_1 = 4;
  4. int const SIZE_2 = 2;
  5.  
  6. int main() {
  7.     int arr[][SIZE_2]    = {{1, 11}, {2, 22}, {3, 33}, {4, 44}};
  8.        
  9.     for (int i = 0; SIZE_2 > i; i++) {
  10.         int temp           = arr[2][i];
  11.         arr[2][i]          = arr[SIZE_2 - 2][i];
  12.         arr[SIZE_1 - 2][i] = temp;
  13.     }
  14.        
  15.     return 0;
  16. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Top