daily pastebin goal
79%
SHARE
TWEET

Untitled

a guest Nov 22nd, 2017 57 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. int a[];
  2. max1 = 0;
  3. max2 = 0;
  4. for (int i = 0; i < n; ++i)
  5.     if (a[i] > max1) {
  6.         max2 = max1;
  7.         max1 = a[i];
  8.         continue;
  9.     }
  10. if (a[i] > max2)
  11. max2 = a[i];
RAW Paste Data
Top