Write a C++ Program to find the greatest number between two numbers.


SUBMITTED BY: Nrupeshsinh

DATE: June 23, 2016, 10:20 a.m.

FORMAT: Text only

SIZE: 224 Bytes

HITS: 795

  1. # include<iostream.h>
  2. # include<conio.h>
  3. void main()
  4. {
  5. clrscr();
  6. int n,m,max;
  7. cout<<"Enter a Number :";
  8. cin>>n;
  9. cout<<"Enter a Number :";
  10. cin>>m;
  11. max=(n>m)?n:m;
  12. cout<<"Greatest Number:"<<max;
  13. getch();
  14. }

comments powered by Disqus