#include<iostream.h>
#include<conio.h>
int maximum(int a,int b, int c);
void main()
{
int x,y,z,max;
cout<<"enter three numbers ";
cin>>x>>y>>z;
max=maximum(x,y,z);
cout<<"maximum is "<<max;
getch();
}
int maximum(int a,int b,int c)
{
if(a>b)
if(a>c)
return a;
else
return c;
else
if(b>c)
return b;
else
return c;
}
#include<conio.h>
int maximum(int a,int b, int c);
void main()
{
int x,y,z,max;
cout<<"enter three numbers ";
cin>>x>>y>>z;
max=maximum(x,y,z);
cout<<"maximum is "<<max;
getch();
}
int maximum(int a,int b,int c)
{
if(a>b)
if(a>c)
return a;
else
return c;
else
if(b>c)
return b;
else
return c;
}