WRITE A Program To Find A Maximum Number Through Function

4/17/2013 07:40:00 pm Unknown 0 Comments

#include<stdio.h>
#include<conio.h>
 int max (int ,int );// function protype
int main()
{
   
    int a,b;
    scanf("%d %d",&a,&b);
    max(a,b); //function call
    printf("ok");
    getch();
}
int max (int x,int y)// function definition
{  
     if(x>y){
   printf("max is %d",x);
   }
     if(y>x){
          printf("max is %d\n",y);
     }}