Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- main(){
- int a,b,c,max;
- printf("entez a = ");
- scanf("%d",&a);
- printf("entez b = ");
- scanf("%d",&b);
- printf("entez c = ");
- scanf("%d",&c);
- max = c ;
- if( a > b && a > c ) {
- max = a;
- }
- if( b > a && b > c) {
- max = b;
- }
- printf("le plus grande valeur de a , b et c est : %d \n\n",max);
- if( a > b && a > c ) {
- printf("le plus grande valeur de a , b et c est a = %d \n\n",a);
- }else if( b > a && b > c) {
- printf("le plus grande valeur de a , b et c est b = %d \n\n",b);
- }else{
- printf("le plus grande valeur de a , b et c est c = %d \n\n",c);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement