-Pages-

Greater Between Three Numbers...

Program used to identify the greater number among the three number.
User can input any desire valid input in the program.
use of nested if else



Source Code:-

#include<iostream.h>
#include<conio.h>
void main()
{clrscr();
 float a,b,c;
 cout<<" Greater no. between three (by:Tarun Rawat)\n \n";
 cout<<" enter three no \n";
 cin>>a>>b>>c;
if(a>b && a>c)
    cout<<"\ngreater no  " <<a;
else { if(b>a && b>c)
   cout<<"\ngreater no " <<b;
       else cout<<"\ngreater no is "<<c;
      }
getch();
}





No comments:

Post a Comment