Showing posts with label if statement example. Show all posts
Showing posts with label if statement example. Show all posts
Saturday, 13 July 2013
Monday, 8 July 2013
IF Statement tutorial in C++
#include<iostream.h>
#include<conio.h>
void main()
{
clrscr() ; //to clear output screen at the beginning
int i ; //decleration
cout<<"Enter any number: ";
cin>>i ;
if( i > 50 )
{
cout<<"The number is greater than 50 ";
cout<<endl;
}
getch();
}
#include<conio.h>
void main()
{
clrscr() ; //to clear output screen at the beginning
int i ; //decleration
cout<<"Enter any number: ";
cin>>i ;
if( i > 50 )
{
cout<<"The number is greater than 50 ";
cout<<endl;
}
getch();
}
Subscribe to:
Comments (Atom)

.png)