Greatest from two Numbers


#include<iostream.h>
#include<conio.h>

void main()
{
    int a, b;
    clrscr();

    cout<<"Enter two numbers:";
    cin>>a>>b;

    if( a == b)
        cout<<"Both numbers are same";
    else if(a > b)
        cout<<"First number is greatest";
    else
        cout<"<"Second number is greatest";
}
Previous Post Next Post