9 Nov 2013

c ++for c++ programmers

for finding the number <,>or =

#include "iostream.h"
#include "stdio.h"

void main( );
{
icin>>a
 cin>>b

if (a>B)
{
cout<<"greatest no =",a;
}
else if   (a<b)
{
cout<<("greatest no = ",b;
}
else if   (a=b)
{
cout<<"all are equal ";
}
else
{
cout<<"wrong input"
getchar( );
}
output
23
34
greatest no=34

No comments:

Post a Comment