Two numbers are taken from user and greatest of two is determined.
Select To use this code as it is.. select and copy paste this code into code.cpp file :)
- #include <iostream.h>
- #include <conio.h>
- void main()
- {
- clrscr();
- int a,b;
- cout<<"Please enter two nos. ";
- cin>>a>>b;
- //Coding by: Snehil Khanor
- //http://WapCPP.blogspot.com
- if (a>b)
- cout<<"a is greatest";
- else
- cout<<"b is greatest";
- getch();
- }
0 comments:
Post a Comment