A good answer might be:
When execution got to theHow much cash? 50000 How much credit do you have? 75000 Enough to buy this car! if statement, it found that
andcash >= 25000 --- true, because 50000 >= 25000 Since all that is required for OR is one true, the complete logical expression was true.credit >= 25000 --- true, because 75000 >= 25000 |
OR OperatorThe or-operator is used in a logical expression to insist that there is at least one true. If both sides are true, the entire expression is true. If just one side is true, the entire expression is true. If both sides are false, the entire expression is false. the or-operator is a logical operator because it combines two true/false values into a single true/false value.
A compact way of saying what || does is:
|
QUESTION 17:Here is a logical expression: Is the complete logical expression true or false ? Click Here after you have answered the question34 > 2 || 5 == 7 |