Answer the following statements true (T) or false (F)

1. You should be careful when using the equality operator to compare floating point values because of potential round-off errors.
2. As a rule of style, when writing an if statement you should indent the conditionally-executed statements.
3. The following code correctly determines whether x contains a value in the range of 0 through 100, inclusive.
if (x > 0 && <= 100)

4. The value of result in the following expression will be 0 if x has the value of 12.
result = x > 100 ? 0 : 1;

5. The conditional operator takes two operands.


1. T
2. T
3. F
4. F
5. F

Computer Science & Information Technology

You might also like to view...

Keyword is used for constants whose values cannot be determined at compile time.

a) Const b) ReadOnly c) Shared d) None of the above.

Computer Science & Information Technology

You can view messages in the mbox file by using the ____ command.

A. mail -s B. mail -l C. mail -v D. mail -f

Computer Science & Information Technology

A password ________ disk stores information about your account so that you can recover your user account and personalized settings

A) setting B) encryption C) cracker D) reset

Computer Science & Information Technology

Taxonomy is a methodical, scientific way of unambiguously ____ information.

A. classifying B. interpreting C. storing D. downloading

Computer Science & Information Technology