Write a boolean expression that evaluates to true if the number is between 1 and 100 or the number is negative.
Explanation / Answer
First of all, the number needs to be between 1 and 100 --> 1 1) AND (num < 100) --> the AND can also be && in most progr. languages the second part is 'num is negative' --> ( num < 0 ) since it's either 'between 1 and 100' OR 'negative', you use the OR to chain the two together, putting the first one in brackets (this is not really necessary, since AND is stronger than OR, but it helps visually. in fact, you don't need any brackets in this case) --> (( num > 1 ) AND (num < 100)) OR (num < 0)