write a c++program by using if statement to read a number and check whether it is positive or negative
Negative * positive = negative Positive * positive = positive Negative * negative = positive
* If "a" is positive, "-a" is negative.* If "a" is negative, "-a" is positive. * If "a" is zero, "-a" is zero. If you want to force a negative number, you can write -|a|, i.e., the negative of the absolute value.
if p represents your positive number, and n represents all of your negative numbers, then: |∑n| < p
if it is not like that then the answer wont be write. Well, It is to be known that two negatives make a positive.
neutral
-- Remember which one was positive and which was negative, then forget about the signs.-- Write down the one that was positive-- Subtract from it the one that was negative(Notice that if the negative one was bigger, then the answer will be negative.)
6 + - 1 = 5 Here is a little table to help with manipulating double signs. = + = - = - = + NB If no sign is given then read it as (+). So for the above sum we could write + 6 + - 5 = +5
Positive + Negative = Negative Negative + Negative = Positive Positive + Positive = Positive Negative + Positive = Negative
write a c++program by using if statement to read a number and check whether it is positive or negative
Negative * positive = negative Positive * positive = positive Negative * negative = positive
* If "a" is positive, "-a" is negative.* If "a" is negative, "-a" is positive. * If "a" is zero, "-a" is zero. If you want to force a negative number, you can write -|a|, i.e., the negative of the absolute value.
if p represents your positive number, and n represents all of your negative numbers, then: |∑n| < p
if it is not like that then the answer wont be write. Well, It is to be known that two negatives make a positive.
if p represents your positive number, and n represents all of your negative numbers, then: |∑n| < p
you don't write anything, it is your creditors who report the information weather it be positive or negative.
The rules for the sign (positive or negative) of the result of a multiplication is the same as division. For multiplication: Positive * Positive --> Positive Positive * Negative --> Negative Negative * Positive --> Negative Negative * Negative --> Positive For division: Positive / Positive --> Positive Positive / Negative --> Negative Negative / Positive --> Negative Negative / Negative --> Positive