#include
#include
int maximo()
{
int n1, n2;
int max;
cout << "Ingrese n1: ";
cin>>n1;
cout << "Ingrese n2: ";
cin>>n2;
max=(n1,n2);
if(n1>n2)
max=n1;
else
max=n2;
return max;
};
int main()
{
int max;
max=maximo();
cout<<"El numero mayor es:"<< max;
}
No hay comentarios:
Publicar un comentario