The following conditional expression is written in the C language. It is true when the value of the variable a is outside the range of 20 to 30 (including end points) and false otherwise:
!(a < = 20 && a > = 30)
Which of the following conditional expressions is equivalent?
a) a>20 &&a<30
b) a<20 &&a>30
c) a>=20 &&a<=30
d) a>20 Ha<30
e) a < = 20 II a > = 30
f) a<20 Ila>30
d) a>20 Ha<30
Approach: Remove the not operator (!)
Flip applicable relational operators (< = becomes > and > = becomes <)
Flip applicable logical operators (&& becomes II)
You might also like to view...
A network that covers a wider area, such as several buildings or cities, is called a wide area network or WAN.
Answer the following statement true (T) or false (F)
The ________ font effect in Word is typically used in titles
A) uppercase B) lowercase C) small caps D) large caps
In the accompanying figure, Item 2 points to a(n) ____.
A. image resizing handle B. text wrapping button C. picture style button D. format picture handle
When you purchase a web hosting service, you are purchasing both space and function on the World Wide Web.
Answer the following statement true (T) or false (F)