Write a CPP program to find greater between two numbers

 Code:-

#include<bits/stdc++.h>
using namespace std;
int main()
{
int a,b;
cout<<“Enter two numbersn”;
cin>>a>>b;
if(a>b)
cout<<a<<” is greater than “<<b;
else
cout<< a<<” is less than “<<b;
return 0;
}

Output:-

Enter two numbers
12 3
12 is greater than 3




Leave a Reply

Your email address will not be published.