IBM C9050-041 - Programming with IBM Enterprise PL/I Exam

Question #11 (Topic: Topic 1)
Which of the following loops will run infinitely?
A. DCL I FIXED BIN (31);DO I = 1 BY 2 UNTIL (I = 20);PUT (I);END; B. DCL I FIXED BIN (31);DO I = 1 BY 2 UNTIL (I > 20);PUT (I);END; C. DCL I FIXED BIN (31);DO I = 1 BY 2 WHILE (I < 20);PUT (I);END; D. DCL I FIXED BIN (31);DO I = 1 BY 2 WHILE (I = 20);PUT (I);END;
Answer: A
Question #12 (Topic: Topic 1)
Given the following code, how many elements of A will contain a value of 0 after execution
of the loops?
DCL A DIM (8, 10) FIXED BIN (31);
DCL (I, K) FIXED BIN (31) INIT (0);
A = 0;
DO I = 2 TO 8;
DO K = 1 TO 10;
A(I, K) = I*K;
END;
END;
A. 0 B. 1 C. 8 D. 10
Answer: D
Question #13 (Topic: Topic 1)
What code will print the value of A to SYSPRINT?
DCL A DEC FIXED(5,3) INIT(12.0);
A. PUT SKIP LIST('Value of A is:' !! A); B. PUT SKIP LIST('Value of A is:'), (A); C. PUT SKIP LIST('Value of A is:')(A); D. PUT SKIP LIST A;
Answer: A
Question #14 (Topic: Topic 1)
Which of the following is a BIN FIXED constant?
A. '1000' B. 1E+03 C. 1000 D. 1000B
Answer: D
Question #15 (Topic: Topic 1)
What does BX.WOK.LOAD refer to in the following job control statement?
//ACCOUNT DD DSN=BX.WOK.LOAD,DISP=SHR
A. It is the connection between program and dataset. B. It is the physical dataset name. C. It is the logical dataset name. D. It is the name which must be referred to in the program.
Answer: B
Download Exam
Page: 3 / 30
Total 146 questions