karimsqualli96

exo 1 - c

Jan 6th, 2014
125
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.38 KB | None | 0 0
  1. #include <stdio.h>
  2. #include <stdlib.h>
  3.  
  4. int main()
  5. {
  6.     int a,b,c;
  7.     printf("Veuillez entrer 3 valeur entier : ");
  8.     scanf("%d %d %d", &a, &b, &c);
  9.  
  10.     printf("le plus petit est : ");
  11.  
  12.     if(a <= b && a <= c)
  13.         printf("%d", a);
  14.     else if(b <= a && b <= c)
  15.         printf("%d", b);
  16.     else
  17.         printf("%d", c);
  18.  
  19.     printf("\n");
  20.     system("pause");
  21. }
Advertisement
Add Comment
Please, Sign In to add comment