0% (0 out of 17 correct) |
|
![]() | 1. |
An imperative statement performs an operation only when an existing condition is true.
![]() Level: easy |
![]() | 2. |
The following is a conditional statement: PERFORM 300-LABEL-RTN
![]() Level: easy |
![]() | 3. |
IF-THEN-ELSE statements are used to code conditional control structures.
![]() Level: easy |
![]() | 4. |
In an IF statement, a CONTINUE clause may be used with an ELSE clause.
![]() Level: medium |
![]() | 5. |
Alphanumeric comparisons may vary in result from one computer to another.
![]() Level: medium |
![]() | 6. |
Numeric comparisons may vary in result from one computer to another.
![]() Level: easy |
![]() | 7. |
The following conditions are equivalent: (1) A NOT > B (2) A < = B
![]() Level: medium |
![]() | 8. |
The condition NOT NEGATIVE is equivalent to the condition POSITIVE.
![]() Level: medium |
![]() | 9. |
A condition-name is defined on level 66 in the DATA DIVISION.
![]() Level: medium |
![]() | 10. |
ASCII is an example of a commonly used internal code for representing alphanumeric data.
![]() Level: easy |
![]() | 11. |
In a compound conditional, the reserved word OR is used when all of several conditions must be met in order for a statement to be executed.
![]() Level: easy |
![]() | 12. |
A CLASS test will test if a field is POSITIVE, NEGATIVE or ZERO.
![]() Level: easy |
![]() | 13. |
With DeMorgan's Rule, the condition NOT ( A = 5 AND B = 9 ) is equivalent to the condition NOT A = 5 AND NOT B = 9
![]() Level: hard |
![]() | 14. |
In COBOL what multiple selection structure is implemented with the verb
EVALUATE? ___________________________________________________________ YOUR ANSWER: ![]() See page 301 Level: easy |
![]() | 15. | CONTINUE is used within what statement where it acts as a place holder? ________ YOUR ANSWER: ![]() See page 308 Level: medium |
![]() | 16. | What value is in Y after the following is executed? ___________________________ IF 1 = 1 OR 5 > 8 AND 3 > 5 MOVE 0 TO Y ELSE MOVE 1 TO Y END-IF YOUR ANSWER: ![]() See page 316 Level: hard |
![]() | 17. | Given the following: 03 VEGETABLE PIC 9. 88 GREEN-BEANS VALUE 1. GREEN-BEANS is true when VEGETABLE has the value ________________________ YOUR ANSWER: ![]() See page 323 Level: easy |
![]() | 18. | Write a single IF statement to PERFORM 500-RTN if NUM is between 5 and 8, inclusive of the end points.__________________________________________________ YOUR ANSWER: ![]() See page 316 Level: medium |
![]() | 19. |
In a nested conditional it is recommended that each IF clause should be
paired with an
_____________________________________________________________________. YOUR ANSWER: ![]() See page 311 Level: medium |
![]() | 20. | Given the following sentence: IF A = 2 IF B = 1 PERFORM 300-RTN-1 ELSE PERFORM 300-RTN-2 END-IF ELSE IF B = 2 PERFORM 300-RTN-3 ELSE PERFORM 300-RTN-4 END-IF END-IF What routine is executed if A = 1 and B = 2? ___________________________________ YOUR ANSWER: ![]() See page 316 Level: medium |
![]() | 21. | Given the statement: IF A = 1 AND B = 2 AND C = 3 PERFORM 300-A-RTN ELSE PERFORM 300-B-RTN END-IF When will 300-A-RTN be performed? ________________________________________ YOUR ANSWER: ![]() See page 316 Level: medium |
![]() | 22. |
Which of the following is NOT a reserved word?
![]() Level: easy |
![]() | 23. |
Which of the following is NOT a legal scope terminator?
![]() Level: medium |
![]() | 24. |
Each of the following terms is valid in a COBOL IF-statement EXCEPT:
![]() Level: medium |
![]() | 25. |
Which of the following conditions is illegal in COBOL?
![]() Level: medium |