daily pastebin goal
31%
SHARE
TWEET

Untitled

a guest Dec 15th, 2018 49 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. int max, tmp;
  2.     int mi, mj;
  3.     for (j = 0; j < m; j++) {
  4.         max = arr[0][j];
  5.         for (i = 0; i < n; i++) {
  6.             if (max < arr[i][j]) {
  7.                 max = arr[i][j];
  8.                 mi = i;
  9.                 mj = j;
  10.             }
  11.         }
  12.         tmp = arr[0][j];
  13.         arr[0][j] = max;
  14.         arr[mi][mj] = tmp;
  15.     }
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