All About Programming
Our Team
Home
C++/C
OOP
Downloads
Softwares
Programs
Games
Web Development
HTML5
CSS3
JavaScript
Projects
C++
OOP
Uncategorized
Wednesday, 8 July 2015
Home
»
C++
» Write a c++ program that tell us the number is positive or negative
Write a c++ program that tell us the number is positive or negative
By
waqar
11:02
No comments
#include<iostream>
using namespace std;
int main()
{
int a;
cout<<"enter a num: ";
cin>>a;
if(a>0){
cout<<"num is Positive:"<<endl;
}else
if(a<0){
cout<<"num is -ve: "<<endl;
}else
cout<<"num is zero"<<endl;
}
Email This
BlogThis!
Share to X
Share to Facebook
← Newer Post
Older Post →
Home
0 comments:
Post a Comment
I am the Author
Popular
Tags
Blog Archives
Followers
The While Loop
while ( condition ) { code block to be executed } The Do/While Loop do { code block to be executed } while ( conditio...
Background Properties
The background-color Property: body {background-color:# cccccc ; color:#000000;} p {background-color:#FF0000; color:#FFFFFF ;} Th...
JavaScript Variables
JavaScript variables are "containers" for storing information : var pi=3.14; var person="John Doe"; var answer=...
Sending Form Data to the Server
The method attribute can take one of two values, either get or post, corresponding to the HTTP methods used to send the form data. If the ...
Difference b/w HTML4 & HTML5
Tic Tac Toe
Free Download
Javascript Examples
<!DOCTYPE html> <html> <body> <script> var x=5; var y=6; var z= x+y ; document.write (x + ...
JavaScript Arrays Example
<!DOCTYPE html> <html> <body > <script> var i ; var cars = new Array(); cars[0] = "Saab"; ...
JavaScript Functions
A function is a block of code that will be executed when "someone" calls it : <!DOCTYPE html> <html> <head...
Multiple Style Sheets
¢ If some properties have been set for the same selector in different style sheets, the values will be inherited from the more specific sty...
About Me
waqar
View my complete profile
Blog Archive
►
2016
(81)
►
December
(3)
►
January
(78)
▼
2015
(20)
▼
July
(20)
Waqar Khan KPSI} WAQAR & FAHEEM
Pattern Printing in C++
Daimond pattern by inputing number of rows in C++
Amazing Daimond in C++
Pattern in C++
Write a c++ program that tell us the number is pos...
How to find largest number in C++
Count number of line in c++
Alphabet to ASCII in C++
prime number in c++
Ascending or descending Order in C++
Even/Odd in c++
Simple Calculator in C++
Keyboard Shorcuts (Microsoft Windows)
Switch Statement Example Program
Gotoxy concept with example program
Calculatar in C++
How to make a diamond in C++?
Program using Gotoxy
How to merge two arrays?
Waqar khan. Powered by
Blogger
.
Contact us
Name
Email
*
Message
*
Tags
Artificial Intelligence
C++
CSS3
HTML5
JavaScript
oop
Project
Video of the Day
Know us
Social
Newsletter
Labels
Artificial Intelligence
C++
CSS3
HTML5
JavaScript
oop
Project
Blog Archive
►
2016
(81)
►
December
(3)
►
January
(78)
▼
2015
(20)
▼
July
(20)
Waqar Khan KPSI} WAQAR & FAHEEM
Pattern Printing in C++
Daimond pattern by inputing number of rows in C++
Amazing Daimond in C++
Pattern in C++
Write a c++ program that tell us the number is pos...
How to find largest number in C++
Count number of line in c++
Alphabet to ASCII in C++
prime number in c++
Ascending or descending Order in C++
Even/Odd in c++
Simple Calculator in C++
Keyboard Shorcuts (Microsoft Windows)
Switch Statement Example Program
Gotoxy concept with example program
Calculatar in C++
How to make a diamond in C++?
Program using Gotoxy
How to merge two arrays?
Recent Posts
Text Widget
Download
0 comments:
Post a Comment