#include <stdio.h>
void max()
{
int a, b;
printf("Ingrese el primero numero entero\n");
scanf("%d",&a);
printf("Ingrese el segundo numero entero\n");
scanf("%d",&b);
if (a>b)
printf("El numero maximo es %d y el numero minimo es %d", a,b);
else if (b>a){
printf("El numero maximo es %d y el numero minimo es %d", b,a);}
else if (a==b)
printf("No existe maximo y minimo por que los numeros son iguales");
else
printf("ERROR, se ha ingresado un valor no valido");
}
int main()
{
max();
}
No hay comentarios:
Publicar un comentario