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

1. The if, while and for statements control only one statement.
2. Given the declaration int x = 0;
The following expression causes a divide by zero error:
(x !=0) || (2/x < 1);
3. Suppose we have these declarations,
int x = -1, y = 0, z = 1;
This Boolean expression is correct and it does what the programmer intends.
x < y < z
4. You want to determine whether time has run out. The following code correctly
implements this. !time > limit
5. The value of count is 0; limit is 10. Evaluate:
(count == 0)&&(limit < 20)

1. True
2. False.
3. False
4. False.
5. true

Computer Science & Information Technology

You might also like to view...

The ________ should be used to make sure your files are backwards compatible

Fill in the blank(s) with correct word

Computer Science & Information Technology

Step 3 in problem solving is to identify alternative ways to solve the problem. This means:

a. To define the knowledge base of all participant b. To write a list of pros and cons for each solution. c. To identify as many solutions as possible to the problem. d. To identify a few solutions to the problem.

Computer Science & Information Technology