SHARE
TWEET

Untitled

a guest Sep 18th, 2019 115 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #include <stdio.h>
  2.  
  3. int main(void)
  4. {
  5.     int a[10];
  6.     int max = 0, min;
  7.     printf("%d",min);
  8.     for(int i = 0;i < 10;i++)
  9.     {
  10.         scanf("%d",&a[i]);
  11.         if(a[i] > 0) max = a[i];
  12.         if(a[i] < 0 && abs(a[i]) < abs(min)) min = a[i];
  13.     }
  14.     printf("%d %d", max, min);
  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