Professional Documents
Culture Documents
com
000-042
IBM
Developing with IBM Enterprise PL/I
http://www.twpass.com/twpass.com/exam.aspx?eCode= 000-042
The 000-042 practice exam is written and formatted by Certified Senior IT Professionals working in
today's prospering companies and data centers all over the world! The 000-042 Practice Test covers all
the exam topics and objectives and will prepare you for success quickly and efficiently.
The 000-042 exam is very challenging, but with our 000-042 questions and answers practice exam,
you can feel confident in obtaining your success on the 000-042 exam on your FIRST TRY!
IBM 000-042 Exam Features
- Detailed questions and answers for 000-042 exam
- Try a demo before buying any IBM exam
- 000-042 questions and answers, updated regularly
- Verified 000-042 answers by Experts and bear almost 100% accuracy
- 000-042 tested and verified before publishing
- 000-042 exam questions with exhibits
- 000-042 same questions as real exam with multiple choice options
Acquiring IBM certifications are becoming a huge task in the field of I.T. More over these
exams like 000-042 exam are now continuously updating and accepting this challenge is itself a task.
This 000-042 test is an important part of IBM certifications. We have the resources to
prepare you for this. The 000-042 exam is essential and core part of IBM certifications and
once you clear the exam you will be able to solve the real life problems yourself.Want to take
advantage of the Real 000-042 Test and save time and money while developing your skills to pass
your IBM 000-042 Exam? Let us help you climb that ladder of success and pass your 000-042 now!
000-042
QUESTION: 1
The XMLCHAR builtin function provides the ability to do which of the following?
QUESTION: 2
Which of the following is a typical deadlock situation? Situation 1: Transaction A waiting for
resource_2 and Transaction B waiting for resource_1 while resource_1 is held by Transaction
C and resource_2 is held by Transaction B Situation 2: Transaction A waiting for resource_1
and Transaction B waiting for resource_2 while resource_1 is held by Transaction B and
resource_2 is held by Transaction C Situation 3: Transaction A Waiting for resource_2,
Transaction B waiting for resource_3, Transaction C waiting for resource_1 ,while resource_1
,resource_2 and resource_3 are held by Transactions A, B and C respectively. Situation 4:
Transaction B waiting for resource_1 and Transaction C waiting for resource 2 while
resource_1 is held by Transaction C and resource_2 is held by Transaction A
A. Situation 1
B. Situation 2
C. Situation 3
D. Situation 4
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=2
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 3
Requirement: If the value of the numeric variable I is 1 it needs to be changed to 2 and vice
versa. In all other cases it must remain unchanged. Which of the following solutions meets the
requirement and does not require essential structural modifications when the requirement is
changed to the following: If the value of the numeric variable I is 512 it needs to be changed to
731 and if the value is 814 it needs to be changed to 5. In all other cases it must be set to 111.
A. lF I = 1 ! 1 = 2 THEN I = 3 - I;
B. DCL ONETWO(2) BIN FIXED(15) INIT(2,1); IF I = 1! I = 2 THEN I =
ONETWO(I);
C. SELECT (I); WHEN(1) I = 2; WHEN(2) I = 1; OTHER; END;
D. IF I = 1 THEN I = 2; IF I = 2 THEN I = 1;
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=3
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 4
Which of the following is LEAST likely to be performed by an online application?
A. Checkpoint/restart logic
B. Transaction processing
C. End user interaction
D. Sorting
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=4
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 5
Which of the following PL/I features is NOT new with Enterprise PL/I?
QUESTION: 6
The lead developer on a project has just learned that Pat, a highly skilled programmer on the
team, has been reassigned. The lead developer is familiar with Pats work and is concerned
because no one on the team has the necessary skills to pick up the work immediately. A new
employee with the required skills is joining the team next week, but the timeline for a mission
critical milestone has been moved up to the end of this week. Which of the following is the
most appropriate action for the lead developer to take to ensure that the critical milestone is
met?
A. Direct the team to cover all of Pats work until the new employee arrives.
B. Explain to the team why this change in schedule is important to the customer.
C. Personally cover the work until the new employee arrives.
D. Explore with the team whether they will be able to meet the new deadline.
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=6
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 7
Given the following declarations, which statement correctly refers to X? DCL R CHAP(10);
DCLX CHAR(10) BASED; DCL P PTR; DCLZ CHAR(10); P = ADDR(R);
A. Z = P -> X;
B. P = ADDR(X);
C. Z = X;
D. X=THIS IS X;
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=7
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 8
Prerequisite: A sorted input dataset with record length 100 contains at least one record for each
of the values 1, 2, 3 in the first byte. The applied sort criteria is 1,100,ch,a. Requirements:
1.) All records with 1 in the first byte must be ignored. 2.) All records with 2 in the first
byte must be written to the output dataset. 3.) If there is a 3 in the first byte, the read iteration
must be left. 4.) The program must not abend or loop infinitely. If the code below does not
fulfill the specifications provided above, which of the following is the most likely reason?
DCL DDIN FILE RECORD INPUT; DCL DDOUT FILE RECORD OUTPUT; DCL 1
INSTRUC, 3 A CHAR(1), 3 * CHAR(99); DCL EOF_IN BIT(1) INIT(0B); DCL
(Z1,Z2,Z3,ZO) BIN FIXED(31) INIT(0); ON ENDFILE(DDIN) EOF_IN = 1B; READ
FILE(DDIN) INTO (INSTRUC); LOOP: DO WHILE (^EOF_IN); SELECT(INSTRUC.A);
WHEN(1) DO; Z1 +-= Z1; ITERATE LOOP; END; WHEN(3) DO; Z3 = Z3+1;
LEAVE LOOP; END; WHEN(2) DO; Z2 = Z2+1; WRITE FILE(DDOUT)
FROM(INSTRUC); END; OTHER DO; ZO = ZO+1; PUT SKIP LIST(INSTRUC.A);
END; END;/*select*/ READ FILE(DDIN) INTO(INSTRUC); END ;/*loop*/
A. The code does not fulfill the requirement because the program will loop infinitely. A.
The code does not fulfill the requirement because the program will loop infinitely.
B. The code does not fulfill the requirement because the last record with 2 in the first
byte will be written twice to the output dataset.
C. The code does not fulfill the requirement because the last record with 2 in the first
byte will be written twice to the output dataset.
C. The code does not fulfill the requirement because not all records with 2 in the first
byte will be written to the output dataset.
C. The code does not fulfill the requirement because not all records with 2 in the first
byte will be written to the output dataset.
D. The code fulfills the requirement.
D. The code fulfills the requirement.
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=8
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 9
Given the following declarations, which code is likely to perform best and correctly initialize
structure 3? DCL 1 S UNALIGNED, 2 A CHAR(3), 2 B BIN FIXED(31), 2 C DEC
FIXED(5); DCL 1 T UNALIGNED LIKE S; T = ;
A. S = ;
B. S = T,BY NAME;
C. CALL PLIFILL(ADDR(S),,STG(S));
D. CALL PLIMOVE(ADDR(S),ADDR(T),STG(S));
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=9
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 10
Given the following declarations, a list of 100 elements must be created so that the element
created last can be accessed as the first element of the list. A new element is always inserted in
front of the element created before. The variable NEXT in the last element should contain the
value NULL. Which of the following pieces of code implements this? DCL 1 NODE BASED
(ANCHOR). 2 NEXT POINTER, 2 DATA FIXED BIN (31); DCL ANCHOR POINTER;
DCL P POINTER INIT (NULL()); DCL I FIXED BIN(31);
QUESTION: 11
In which of the following examples will a dummy argument be passed?
QUESTION: 12
Which of the following will definitely NOT cause an unresolved external entry?
QUESTION: 13
Which of the following best describes an atomic transaction?
A. The database modifications must follow an all or nothing rule
B. Only valid data will be written to database
C. If one part of the transaction fails, the remainder may still be processed
D. Referential Integrity is maintained in the database
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=13
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 14
SUBSCRIPTRANGE checks which of the following?
A. The subscripts of an array are checked for conformance with iSUB defining rules.
B. The address generated for accessing an array element is checked to be sure it falls
within the storage allocated to the array.
C. The value of each subscript used to refer to an array element is checked for validity
after the element is accessed.
D. The value of each subscript used to refer to an array element is checked for validity
before the element is accessed.
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=14
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 15
A program reads a GSAM dataset sequentially, reads complementary information from DB2Databases and uses this information to update an IMS-Database, At the end of the program
statistics about how many records have been read and how many IMS-Segments have been
updated should be printed. The program should write checkpoints regularly and should be
restartable. Which of the following groups of information saved when the checkpoint is written
will provide enough information to be able to restart the program correctly?
A. The key of the last record read from the GSAM dataset and the key of the last IMS
segment changed.
B. The number of records read from the GSAM dataset and the number of IMS
segments changed.
C. The number of records read from the GSAM dataset, the key of the last record read
from the GSAM dataset and the key of the last IMS segment updated.
D. The key of the last IMS segment changed and the number of segments changed.
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=15
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 16
The lead developer is presenting sample code. One of the team members identifies an error in
the code. Which of the following is the most appropriate response for the lead developer to
make?
QUESTION: 17
Given the following code: DCL INDATA FILE RECORD INPUT; DCL INSTRUC
CHAR(100); DCL EOF BIT(1) INIT(0B); ON ENDFILE(INDATA) EOF = 1B; OPEN
FILE(INDATA); READ FILE(INDATA) INTO(INSTRUC); DO WHILE (^EOF); CALL
SR_PROCESS; READ FILE(INDATA) INTO(INSTRUC); END; CLOSE FILE(INDATA);
If the database (input file) changes from OS-PS to DB2 view and the necessary syntax has been
changed accordingly, which of the following DB2-related steps is NOT additionally required to
guarantee the same level of stability and functionality?
QUESTION: 18
What could be used when a structure is passed to a subroutine to verify that the area the
structure occupies in storage has not been overwritten?
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 19
In the following example what value will be printed to SYSPRINT, if any, from the PUT LIST
in PGM_A? PGM_A PROC; DCL INPARM CHAR (10) INIT(FIRST CALL); DCL
P_OUT PTR; DCL OUTPARM CHAR(10) BASED (P_OUT); DCL PGM_B
ENTRY(CHAR(10),PTR) EXTERNAL: CALL P0MB (INPARM,P OUT); IF OUTPARM =
RESULT THEN DO; INPARM = ; CALL PGM_B (INPARM,P_OUT); END; PUT
LIST(OUTPARM); END; PGM_B: PROC(INPARMP_OUT); DCL INPARM CHAR (10);
DCL P_OUT PTR; DCL OUTPARM CHAR (10) INIT(); P_OUT = ADDR(OUTPARM);
IF INPARM =FIRST CALL THEN OUTPARM = RESULT ; ELSE OUTPARM = NO
RESULT; END;
A. Blanks
B. NO RESULT
C. Unpredictable
D. RESULT
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=19
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 20
Which of the following is NOT part of the PL/I code review?
A. Training course for the programs author
B. Attendance of people with technical expertise
C. Decision whether the review object is a appropriate solution
D. Documentation of results of the review
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=20
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 21
Given the following declaration, what declaration of B would cause the structure Ato be
invalid? DCL K FIXED BIN (31) VALUE (10); DCL P POINTER; DCL 1 A BASED (P),
2 B FIXED BIN (31), 2 C DIM (K REFER (B)), 3 D FIXED BIN (31), 3 E CHAR (4);
ALLOCATE A;
QUESTION: 22
Program A calls program B with PC as a parameter defined BIN FIXED (31 .0). Program B
sets PC as follows: 0 OK 4 WARNING 8 ERROR Which of the following is the most
appropriate statement for testing the PC variable?
A. IF (RC ^= 0) & (RC ^= 4) THEN PUT SKIP LIST(ERROR IN B); ELSE IF RC>
8 THEN PUT SKIP LIST(UNKNOWN VALUE FROM B);
B. SELECT (RC); WHEN (0, 4); OTHERWISE PUT SKIP LIST(UNKNOWN
VALUE FROM B); END;
C. IF (RC >4) THEN PUT SKIP LIST(ERROR IN B); ELSE PUT SKIP
LIST(UNKNOWN VALUE FROM B);
D. SELECT (RC); WHEN (0,4); WHEN (8) PUT SKIP LIST (ERROR IN B);
OTHERWISE PUT SKIP LIST(UNKNOWN VALUE FROM B); END;
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=22
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 23
Which of the following statements about the newest PL/l compiler is NOT suitable to convince
a stakeholder that migration to the new PL/I compiler is necessary?
A. The new compiler takes advantage of the current machine instruction set.
B. The new compiler provides new language features.
C. The new compiler will tolerate more erroneous code.
D. The new compiler is necessary because current versions of DB2 and CICS only
officially support compilers which are in service.
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=23
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 24
What are the requirements on data to apply parallelization in a program?
QUESTION: 25
In which of the following groups of compiler options could all the options specified cause the
compiler to generate code which requires more time at execution?
A. ATTRIBUTES(FULL),XREF(FULL),DEFAULT
(EVENDEC,DUMMY(UNALIGNED)),OFFSET
B. OPTIMIZE(0),NOREDUCE,PIREFIX(SIZE,SUBSCRIPTRANGE)
C.
OPTIMIZE(2),DEFAULT(REORDER,NOLAXDCL,NOLAXCTL),STORAGE,MMT
EMP(1000)
D. APCH(5),BIFPREC(31),NOTESTMTUNE(5),NOSERVICE
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=25
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 26
Given the following declaration, how many bytes will be occupied by the structure? DCL 1 A
ALIGNED, 2 B FIXED BIN (31), 2 C CHAR (1), 2 D FIXED BIN (31), 2 E FIXED
DEC (5,2), 2 F POINTER;
A. 16
B. 19
C. 20
D. 24
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=26
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 27
What is the output of the following program? DCL A AREA(8000); DCL 1 STR1
BASED(P), 2 STR1_LGTH BIN FIXED(31), 2 STR_CHAR CHAR(ALLOC_LGTH
REFER(STR1_LGTH)); DCL ALLOC_LGTH BIN FIXED(31); DCL I FIXED BIN(31);
DCL P PTR; ALLOC_LGTH = 100; DO I = 1 TO 10; ALLOC STR1 IN(A); END; PUT
SKIP LIST(CSTG(A));
A. 1016
B. 1040
C. 1056
D. 8000
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=27
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 28
Given the following code, what are the default attributes of DSET1 after the READ statement?
DCL DATA CHAR (80); DCL DSET1 FILE; READ FILE(DSET1) INTO(DATA);
QUESTION: 29
Which compiler option causes the compiler to flag any IF, WHILE, UNTIL and WHEN
clauses that do not have the attributes BIT(1) NONVARYING?
A. RULES(NOLAXWHILE)
B. RULES(NOLAXIF)
C. RULES(NOLAXUNTIL)
D. RULES(NOLAXWHEN)
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=29
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 30
A junior programmer has written a 3000 statement program and has asked the team lead for
help in determining how to review it. Which of the following is the most appropriate response
for the team lead?
QUESTION: 31
What is a program specification document?
QUESTION: 32
The following function converts a character string to uppercase. What is the best way to
improve the performance? SET_TO_UPPERCASE: PROC(CHARSTR) RETURNS
(CHAR(120) VARYING); DCL CHARSTR CHAR(120) VARYING; DCL UC CHAR(26)
QUESTION: 33
What happens after executing the following code, assuming the input file has more than 1
record? DCL INPFILE FILE RECORD INPUT ENV(VB RECSIZE(100)); DCL P PTR;
DCL B CHAR(100) VARYING BASED(P); DCLC CHAR(110) VARYING BASED(P);
READ FILE(INPFILE) SET(P); C=B!! EXTENDED READ FILE(INPFILE) SET(P);
QUESTION: 34
Which software quality describes the ability of software to cooperate with other applications?
A. Reusability
B. Interoperability
C. Scalability
D. Portability
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=34
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 35
Which of the following steps is NOT required to use the IBM Debug Tool on a PL/I program?
QUESTION: 36
The following code is supposed to find the earlier date between todays date and the given
input date which is input to the program in YYYYMMDD format. What happens when the
program is executed? DCL DATE JN CHAR (8); DCL DAT E_MIN CHAR (8); GET
(DATE IN); DATE_MIN = MIN(SUBSTR(DATETIME(), 1, 8), DATE IN);
QUESTION: 37
An external subroutine procedure requires 10 variables belonging to an input file and 10
variables belonging to an output file. What is best practice in passing these variables to the
procedure?
QUESTION: 38
Given the following code, which DECLARE should NOT be used for a reentrant program?
DCL B BIN FIXED(31,0) INIT (4); A = B;
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=38
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 39
What does it mean that an interface is synchronous?
QUESTION: 40
A given PL/I program has a big nesting depth. Which of the following measures will help to
reduce the nesting depth in most cases?
QUESTION: 41
Given the following pseudocode example, at which label should an unconditional COMMIT be
placed assuming there is a one-to-many relationship between FIL01 and FIL02 and FlL01
contains several thousand records? Read record from file FIL01 A: DO while there are
records in FIL01 IF record in FIL01 specifies update THEN DO for all records matching in
FIL02 Update record in FIL02 with information from FIL01 end DO B: end IF C:
Read next record in FIL01 D: end DO
A. A
B. B
C. C
D. D
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=41
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 42
A PL/I program performance analwer can best help identify which of the following?
QUESTION: 43
What happens after the following statements? DCLI,J CHAR(5) INIT(54321); I = J; PUT
LIST(l);
QUESTION: 44
What will be printed, if anything, to SYSPRINT after the following statements are executed?
CALL REVERSEIT(PL/I); (SUBSCRIPTRANGE,SIZE,STRINGSIZE): REVERSEIT:
PROC(31); DCL(I,J) BIN FIXED(31); DCL (S,T) CHAR(100) VARYING; T = S; J = 0; I
= 0; DO I = LENGTH(S) TO 1; J = J + 1; SUBSTR(T,J,1) = SUBSTR(S,I,1); END;
PUT(T); END;
A. PLI
B. I/LP
C. SUBSCRIPTRANGE error will be raised.
D. STRINGSIZE error will be raised.
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=44
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 45
Which PL/I builtin function can be used to get the system return code from a called program
(including non-PL/I languages)?
A. PLIRETC
B. PLIRETV
C. PLIREST
D. PLISTRA
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=45
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 46
The following program was written to copy a dataset with record length of 100 to another
dataset. If this requirement has not been fulfilled, which is the most likely reason? DCL DDIN
FILE RECORD INPUT; DCL DDOUT FILE RECORD OUTPUT; DCL INSTRUC
CHAR(100); DCL EOF_IN BIT(1) INIT(0B); ON ENDFILE(DDIN) EOF_IN = 1B; DO
UNTIL (EOF_IN); READ FILE (DDIN) INTO(INSTRUC); WRITE FILE(DDOUT)
FROM(INSTRUC); END;
QUESTION: 47
Which of the following would a non-technical manager be LEAST interested in regarding
migration to Enterprise PL/I?
QUESTION: 48
Given the following code, which statement will produce an E level preprocessor message?
%DCL ABC ENTRY; %ABC: PROC (X,Y) STATEMENT RETURNS(CHAR); DCL(XY)
CHAR; IF ^PARMSET(X) THEN NOTE(NO X ,0); IF ^PARMSET(Y) THEN NOTE(NO
Y 8); RETURN(/* !!X!!YI!C */); %END ABC;
A. ABC Y(B)X(A);
B. ABC (A,);
C. ABC (A,B);
D. ABC(,B);
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=48
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 49
Given the following example, what will happen with the PUT SKIP DATA statement after the
DO- loop? PGM_A PROC OPTIONS(MAIN); DCL I FIXED SIN (31); DCL MON CHAR
(10); DCL DAY(12) CHAP (2) INIT (31,28,31,
30,31,30
31,31,30
31,30,31); DO I = 1 TO 12; MON = MON_FUNC(I); PUT DATA (MON,DAY(I));
END; PUT SKIP DATA (MON_ARR); MON_FUNC: PROC(INP) RETURNS(CHAP(10));
DCL INP FIXED BIN (31); DCL MON_APP(12) CHAR (10) INIT (JANUARY
,FEBRUARY ,MARCH , APRIL ,MAY JUNE JULY AUGUST
SEPTEMBER,OCTOBER ,NOVEMBER ,DECEMBER );
RETURN(MON_ARR(INP)); END; END;
QUESTION: 50
WIDECHAR can be converted to CHAR. Which rule has to be observed?
A. Each WIDECHAR value has to be less than 0080WX, otherwise CONVERSION
is raised.
B. All WIDECHAR values can be converted to CHAP using the appropriate builtin
function.
C. Each WIDECHAR value has to be less than or equal to 00FFWX, otherwise
CONVERSION is raised.
D. By conversion of WIDECHAR to CHAR the left byte is omitted.
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=50
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 51
Assuming there is no information about the duration or each table update and the programs are
running in a multitasking environment, which of the following options will best minimize the
chance for deadlocks?
A. Program A updates Table A, Table B and Table C in the specified order, and
Program B updates Table B, Table C and Table A in the specified order.
B. Program A updates Table A, Table B and Table C in the specified order, and
Program B updates Table C, Table B and Table A in the specified order.
C. All programs update Table A, Table B and Table C in the same order.
D. Programs update table A, Table B and Table C in random order.
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=51
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 52
The following structure is used when writing a file on Intel architecture which is sent to the
mainframe: DCL 1 A, 2 B FIXED BIN (31), 2 C CHAR (100) VAR, 2 D FIXED BIN
(31); How must this structure be declared on the mainframe if the file is to be read correctly?
QUESTION: 53
Which of the following actions will NOT help increase the maintainability of a program?
QUESTION: 54
In a multithreading environment, when can a race condition occur between two threads?
QUESTION: 55
What characterizes the relational model with respect to data storage?
QUESTION: 56
Given the following (incomplete) code, how is Q to be declared in order to allocate X in A?
DCL A AREA; DCL Q DCL X FIXED BIN (31) BASED (Q); ALLOCATE X;
A. OFFSET(A);
B. POINTER;
C. OFFSET;
D. BASED(A);
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=56
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 57
What would the attribute table in a compile list be used for when looking at the variable in a
dump?
QUESTION: 58
Given the following code, what measure will NOT improve stability? S1: PROC (X,Y,Z);
DCL X DEC FIXED (5); DCL Y PlC 99999; DCL Z DEC FIXED (5); Z = X + Y; END;
QUESTION: 59
Given the following declaration, how many variables are initialized to 0? DCL 1 A DIM (10),
2 B, 3 C FIXED BIN (31) INIT (4, (*)0), 3 D FIXED DEC (5,2) NIT ((4)0), 3 E FIXED
A. 7
B. 15
C. 17
D. 23
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=59
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 60
Input to a SORT routine requires the starting position of each field to be sorted. Which of the
following calculates a value of 5 for field B? DCL 1 S, 2 A CHAR(4), 2 B BIN
FIXED(31);
A. POINTERDIFF(ADDR(S), ADDR(S.B))
B. POINTERDIFF(ADDR(S.B), ADDR(S))
C. POINTERDIFF(ADDR(S.B),ADDR(S)) + 1
D. POINTERDIFF(ADDR(S), ADDR(S.B)) + 1
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=60
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 61
PL/I programs which have been written under Intel architecture are now to be recompiled and
run on the mainframe. What will happen to the programs during compilation and execution?
A. They will not run correctly because the byte order on mainframe is bigendian.
B. They can be recompiled unchanged and will run correctly.
C. They may have to be changed before they run correctly on the mainframe.
D. They will not compile correctly on mainframe because ASCII has no NOT sign.
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=61
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 62
How much storage in bytes will be allocated for the following declaration? DCL 1 S(10)
ALIGNED, 2 A BIN FIXED(15), 2 B DEC FIXED(3), 2 C CHAP(3); A- 70 B- 79 C80 D- 69
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=62
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 63
The lead developer has reviewed the teams progress and determined that the deadline of one
week cannot be met since all of the modules have not been thoroughly tested. Which of the
following is the best action for the lead developer to take?
A. Ask management for more staff to ensure the testing is completed by the deadline.
B. Suggest that management lower the price of the product since it does not have all the
required functionality.
C. Tell managementthatthe quality of the software maybe lowerthan expected but itwill
be delivered on time.
D. Tell management that not all functionality can be provided but those modules
provided will be of high quality.
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=63
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 64
Given the following code example, what is the value of A after the last CALL to ADD_RUT?
PGM2: PROC OPTIONS(MAIN,REENTRANT) REORDER; DCL A BIN FIXED (15); A
=1 CALL ADD_RUT (A); CALL ADD_RUT (A); CALL ADD_RUT (A); ADD_RUT:
PROC (VAL); DCL VAL DEC FIXED (15); VAL = VAL + 1; END ADD_RUT; END
PGM2;
A. 4
B. 3
C. 2
D. 1
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=64
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 65
What happens to STATIC variables declared in a procedure when the procedure is called
recursively?
A. STATIC variables are allocated only once and can, therefore, be used for
communication between invocations.
B. The values of STATIC variables from the previous invocation are saved and are
available when the current invocation ends.
C. The values of STATIC variables from the previous invocation are lost.
D. STATIC variables are allocated and initialized at each new invocation.
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=65
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 66
Which of the following is NOT useful to translate business logic into the appropriate technical
design?
A. GANTT charts
B. Pseudo code
C. Nassi-Shneiderman diagrams (structograms)
D. Jackson Structured Programming method
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=66
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 67
Which of the following compiler options should be checked first when addressing performance
issues in a PL/I program?
QUESTION: 68
A programmer has submitted the following declaration for review. What feedback should be
provided to the programmer? DCL 1 A, 2 B DIM (1000) FIXED BIN (31) INIT (0), 2 C
DIM (1000) FIXED BIN (15) INIT (0);
QUESTION: 69
Which of the following structures will NOT contain padding btes if the PL/I default for
alignment is applied?
A. DCL 1 A, 2 B FIXED BIN (31), 2 C CHAR (2) VAR ALIGNED, 2 D FIXED BIN
(31), 2 E FIXED DEC (1), 2 F CHAR (3) YAP;
B. DCL 1 A ALIGNED, 2 B FIXED BIN (31), 2 C CHAR (2) VAR, 2 D FIXED BIN
(31), 2 E FIXED DEC (1), 2 F CHAR (3) VAR,
C. DCL 1 A, 2 B FIXED BIN (31), 2 C CHAR (2) VAP, 2 D FIXED BIN (31), 2 E
FIXED DEC (1), 2 F CHAR (3) VAR ALIGNED;
D. DCL 1 A, 2 B FIXED BIN (31), 2 C CHAR (2) VAR, 2 D FIXED BIN (31), 2 E
FIXED DEC (1), 2 F FLOAT DEC (6);
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=69
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 70
Given the following code whatwill be output, if an,thing? DCLX FIXED DEC (5,2) INIT (123.45); DCL S CHAR (7); PUT STRING (S) EDIT (X) (A(7)); PUT DATA (5);
A. S= -123.4
B. S=123.45
C. S=-123.45;
D. The program ends abnormally at runtime with condition CONVERSION.
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=70
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 71
Which of the following is a best practice to make debugging easier?
A. Have the calling program test the return code after the call.
B. Use a variable updated with the program name.
C. CALL PLIDUMP(TFCHAB,Spot Dump); at key points in the program logic.
D. Use the runtime option STORAGE(00,,00,0K)
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=71
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 72
Given the following declaration, how many bytes will be occupied by this structure under the
default alignment rules? DCL 1 A DIM (10), 2 B FIXED BIN (31), 2 C CHAR (1)VAR;
A. 70
B. 77
C. 79
D. 80
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=72
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 73
What does it mean that an interface is asynchronous?
QUESTION: 74
Which of the following may be an advantage of the BEGIN OPTIONS (INLINE) statement?
A. The program runs faster because all variables declared inside the BEGIN block are
already allocated when the block containing the BEGIN block is entered.
B. The code runs faster because more variables will be optimized in the BEGIN block.
C. The program uses less stack storage.
D. The program uses less heap storage.
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=74
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 75
Prerequisite: A sorted input dataset with record length 100 contains at least one record for all
the values 1, 2, 3 in the first byte. The applied sort criteria is 1,100,ch,a. Requirements:
1.) All records with 1 in the first byte must be ignored. 2.) All records with 2 in the first
byte must be written to the output dataset. 3.) If there is a 3 in the first byte, the program
must not read more records. 4.) The program must not abend or loop infinitely. If the
following code does not fulfill the requirements above, which would be the reason, if any?
DCL DDIN FILE RECORD INPUT; DCL DDOUT FILE RECORD OUTPUT; DCL 1
INSTRUC, 3 A CHAR(1), 3 * CHAR(99); DCL EOF_IN BIT(1) INIT(0B); DCL
(Z1,Z2,Z3,ZO) BIN FIXED(31) INIT(0); ON ENDFILE(DDIN) EOF IN = 1B; LAB: DO
FOREVER; READ FILE(DDIN) INTO (INSTRUC); IF EOF_IN THEN LEAVE;
SELECT(INSTRUC .A); WHEN(1) DO; Z1 += Z1; ITERATE LAB; END; WHEN(3)
DO; Z3 = Z3 + 1; LEAVE; END; WHEN(2) DO; Z2 = Z2 + 1; WRITE FILE(DDOUT)
FROM(INSTRUC); END; OTHER DO; ZO = ZO + 1; PUT SKIP LIST(INSTRUC.A);
END; END;/*SELECT*/ END;/*LOOP*/
A. The code does not fulfill the requirement, because the program will loop infinitely.
B. The code fulfills the requirement.
C. The code does not fulfill the requirement, because not all records with 2 in the first
byte will be written to the output dataset.
D. The code does not fulfill the requirement, because the READ iteration will not be left
when the first record with 3 in the first byte appears.
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=75
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 76
Which of the following is NOT a builtin subroutine which supports Logical Unit of Work?
A. PLICKPT
B. PLILUW
C. PLIREST
D. PLICANC
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=76
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 77
Which compiler option causes the compiler to flag any reference to structure members that are
not level 1 and are not dot qualified?
A. RULES(NDLAXQUAL)
B. RULES(NOLAXSTRUCT)
C. PULES(NOLAXDOT)
D. RULES(NOLAXLEVEL1)
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=77
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 78
Which software model is LEAST appropriate it requirements keep changing?
A. Waterfall model
B. Spiral model (also known as Iterative model)
C. Rapid Application Development model
D. Object-oriented model
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=78
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 79
A program reads an input file into a structure with 20 fields. Fifteen of these are required as
parameters in an external procedure. Which of the following is the most efficient way of
passing these parameters?
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 80
In the following example how many lines, if any, will be printed? GRAPH: PROC
OPTIONS(MAIN); DCL I FIXED BIN (31); DCL POINTS FIXED BIN (31); CALL
INIT_POINTS; DO I = 1 TO 100; GET LIST(POINTS); CALL
PLOT_NEXT(POINTS); END; INIT_POINTS: PROC; DCL I FIXED BIN (31); DCL
POINTS(1000) FIXED BIN (31); DCL BAR CHAR (100) INIT((100)*) STATIC; DO I 1
TO 10; POINTS(I) = I; PUT SKIP LIST (POINTS(I),SUBSTR(BAR,1,I)); END; RETURN;
PLOT_NEXT: ENTRY(I); POINTS(I) = I; PUT SKIP LIST(POINTS(I),SUBSTR(BAR,1 I));
END; END GRAPH;
A. 10
B. 100
C. 110
D. It is unpredictable as the program will fail.
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=80
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 81
A file containing FIXED BINARY fields that is written by a PL/I program on Intel
Architecture is to be read by PL/I programs on Intel Architecture and on the mainframe. What
must be changed in the program which reads the file on Intel architecture, if anything, for it to
work correctly when it runs on the mainframe?
A. The program must declare the FIXED BINARY fields with the attribute NATIV
E.
B. The program must declare the FIXED BINARY fields with the attribute
LITTLEENDIAN.
C. The program must declare the FIXED BINARY fields with the attribute BIGEND
IAN.
D. Nothing needs to be changed.
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=81
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 82
Given the following code, which procedure call would cause the Pointer corrupted! message
to be output provided that the PL/I compile time option CHECK(STORAGE) has been
specified? DCLX FIXED BIN (31) BASED (P); DCL Y CHAR (5) BASED (P); DCL P
POINTER; SUB: PROCEDURE (P); DCL P POINTER; if CHECKSTG(P) THEN PUT
(Pointer 0k!); ELSE PUT (Pointer corrupted!); END;
A. ALLOCATEX; Y = ABCD; CALL SUB (P);
QUESTION: 83
Given the following declaration, what is the most efficient way of setting C from A? DCLA
BIN FIXED(31) INIT(-123); DCL C CHAR(6); DCL P PlC ---- 9 DEFINED C;
A. C = A;
B. PUT STRING(C) EDIT(A)(F(6));
C. PUT STRING(C) LIST(A);
D. P = A;
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=83
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 84
Which of the following structures will NOT contain padding bytes if the PL/I default for
alignment is applied?
QUESTION: 85
Requirement: All the characters of the CHAR(3) variable X must be tested to be numeric.
Which of the following solutions meets the requirement and does not require essential
structural modifications when the requirement is changed to the following: The first character
of the CHAR(3) variable X must be tested to be uppercase alphabetic, while the two other
characters must be tested to be numeric.
A. IFX >= 000 & X <= 999 THEN ... /*NUMERIC*/
B. DCL NUM CHAR(10) VALUE(0l 23456789); IF VERIFY(X,NUM) = 0 THEN
... /*NUMERIC*/
C. DCL Y PIC999; DCL SWITCH BIT(1) INIT(1B); ON CONVERSION
QUESTION: 86
What is a program internal specification document?
QUESTION: 87
Which of the following is generally NOT an area of concern when calling a program written in
another language from PL/I?
A. Storage management
B. Acceptable calling conventions
C. Data mapping
D. Condition handling
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=87
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 88
Which code should NOT be split out into separate subroutines?
QUESTION: 89
Which of the following is the most appropriate way of avoiding a recursive deadlock?
QUESTION: 90
What will be printed after the following statements? DCL B BIT(5); B = 1; PUT(B);
A. 00001B
B. 00010B
C. 11111B
D. 10000B
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=90
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 91
Given the following code, what measure will improve stability? S1: PROC (I)
RETURNS(CHAR(10)); DCL I BIN FIXED (15); DCL T (-1:1) CHAR(10)
INIT(NOTFOUND ,OK.ENDFILE); RETURN(T(l)); END S1;
QUESTION: 92
Given the following code, what statement will produce an E level diagnostic? %DCL ABC
ENTRY; %ABC: PROC (X,Y) STATEMENT; DCL(X,Y) CHAR; IF ^PARMSET(X)
THEN NOTE(NO X ,0); IF ^PARMSET(Y) THEN NOTE(NO Y ,8); ANSWER(/*
!lX!!Yl!C */); % END ABC;
A. ABC(A,);
B. ABC Y(B)X(A);
C. ABC(,B);
D. ABC (A,B);
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=92
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 93
Which of the following declarations is NOT accepted by the compiler?
QUESTION: 94
Which of the following characters may NOT be translated correctly when moving between
code pages, character sets and platforms?
A. A
B. +
C. 9
D.
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=94
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 95
Which of the following is LEAST likely to be performed by a batch program?
A. Sorting
B. Sequential file processing
C. User interaction
D. Production of pay checks
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=95
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 96
What happens to AUTOMATIC variables when a procedure is called recursively?
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 97
Which of the following is NOT a characteristic of the RANDOM builtin function?
QUESTION: 98
Which of the following is the most likely reason to use a debugger in a production
environment?
A. Enhance performance
B. Ensure data integrity
C. Investigate error situations
D. Test a program
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=98
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 99
Given the following code, which condition would be raised first (if ENABLED)? DCL
A(50000) CHAR (8); DCL I BIN FIXED (31); DCL J BIN FIXED (15); DCI = 1 TO
100_000; J = I; A(J) = I; END;
A. SIZE
B. FIXEDOVERFLOW
C. SUBSCRIPTRANGE
D. CONVERSION
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=99
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 100
When a program reads a variable record format dataset via LOCATE mode, what happens?
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=100
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 101
Requirement: The function LEAPYEAR evaluates a given 4-digit number and returns 1B if
it is a leap year, 0B if it is not. This function is supposed to work for the years 2004 to 2015.
Leap years occur every four years, except for years ending in 00 that are not divisible by 400.
Which of the following solutions meets the requirement and does NOT need to be changed if
the requirement changes to: The function is supposed to work for the years 1900 to 3000.
A. LEAPYEAR: PROC(YEAR) RETURNS(BIT(1)); DCL YEAR PlC 9999; DCL
(MOD,VERIFY) BUILTIN; SELECT; WHEN (VERIFY(YEAR,0l 23456789) ^=
0) RETURN(0B); WHEN (MOD(YEAR,100) = 0) RETURN(0B); WHEN
(MOD(YEAR,4) = 0) RETURN(1B); OTHER RETURN(0B); END; END
LEAPYEAR;
B. LEAPYEAR: PROC(YEAR) RETURNS(BIT(1)); DCL YEAR PlC 9999; DCL
VERIFY BUILTIN; IFVERIFY(YEAR,0123456789)^= 0 THEN RETURN(0B);
SELECT(YEAR); WHEN (2004) RETURN(1B); WHEN (2008) RETURN(1B);
WHEN (2012) RETURN(1B); OTHER RETURN(0B); END; END LEAPYEAR;
C. LEAPYEAR: PROC(YEAR) RETURNS(BIT(1)); DCL YEAR PlC 9999; DCL
(MOD,VERIFY) BUILTIN; SELECT; WHEN (VERIFY(YEAR 0123456789) ^=
0) RETURN(0B); WHEN (MOD(YEAR,400) = 0) RETURN(lB); WHEN
(MOD(YEAR,100) = 0) RETURN(0B); WHEN (MOD(YEAR,4) = 0)
RETURN(1B); OTHER RETURN(0B); END; END LEAPYEAR;
D. LEAPYEAR: PROC(YEAR) RETURNS(BIT(1)); DCL YEAR PlC 9999; DCL
(MOD,VERIFY) BUILTIN; SELECT; WHEN (VERIFY(YEAR 0123456769) ^=
0) RETURN(0B); WHEN (MOD(YEAR,100) = 0) RETURN(0B); WHEN
(MOD(YEAR,400) = 0) RETURN(1B); WHEN (MOD(YEAR,4) = 0)
RETURN(1B); OTHER RETURN(0B); END; END LEAPYEAR;
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=101
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 102
Given the following declarations, which is the WORST way of setting D from 5? DCL 1 S, 2
A(100) CHAR(1), 2 B(100) CHAR(2), 2 C(100) CHAR(3); S = ; DCL D CHAR(600);
DCLI BIN FIXED(31);
A. D = STRING(S);
B. CALL PLIOVER(ADDR(D)ADDR(S),600);
C. DO I = 1 TO 100; SUBSTR(D,I,1) = S.A(l); SUBSTR(D,1 01 + ((I-1) *2),2) =
S.B(I); SUBSTR(D,301 + ((I-1) *3),3) = S.C(I); END;
D. D= STRING(A) !! STRING(S) !! STRING(C);
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=102
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 103
What will be printed after the following statements? DCL S CHAR(10); S = 0; S = S + 1;
PUT(S);
A. 1 followed by 9 blanks
B. 8 blanks followed by 1 followed by a blank
C. 9 blanks followed by 1
D. 10 blanks
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=103
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 104
A software package utilizes several licensed third party software components and will be sold
to multiple customers who will also need runtime licenses. What information is LEAST
appropriate to provide in a technical operations guide?
QUESTION: 105
In a multithreading environment, when can a deadlock occur between two threads, if at all?
QUESTION: 106
Which of the following is the most appropriate reason to explicitly use COMMIT or
ROLLBACK?
A. A batch program performs mass deletions where all deleted rows are independent
from each other.
B. An online program updates DB2 and IMS objects.
C. The program abends.
QUESTION: 107
An online, non-conversational main program (for CICS or IMS) contains all of the logic for a
one- screen (MAP or FORMAT) application. Which of the following will NOT be required?
QUESTION: 108
Given the following declaration, W has to be assigned to C. How can a CONVERSION
condition be avoided? DCL C CHAR(1); DCL W WIDECHAR(1); A - IF RANK(W)> 127
THEN PUT (Widechar is not a valid char!); ELSE C = W; B - IFW ^= CHAR(W)THEN
PUT (Widechar not is a valid char!); ELSE C = W; C - IF WCHARVAL(W) > 128 THEN
PUT (Widechar is not a valid char!); ELSE C = W; D - IFW >128THEN PUT (Widechar
is not a valid char!); ELSE C = W;
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=108
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 109
Which of the following statements is best for avoiding synchronously updating a resource?
QUESTION: 110
A lead developer reviewing code from one of the programmers found the following code. What
should the programmer be told about BY NAME assignments? DCLl STR1, 3FB15 FIXED
BIN (15), 3 CH10 CHAR (10), 3 NAME CHAR (25). 3 ADDR CHAR (30), 3 FB31
FIXED BIN (31); DCL 1 STR2, 3 FB31 FIXED BIN (31), 3 FB31B FIXED BIN (31), 3
NAME CHAR (20), 3 ADDR CHAR (30), 3 CH20 CHAR (20); STR2 = STR1, BY
NAME;
QUESTION: 111
A member of the team points out to the lead developer that there appears to be an error in the
program the lead developer has created. Which of the following is the most appropriate
response from the lead developer?
A. Thank the programmer, indicating the code will be revised and provided to the team
for review.
B. Thank the programmer, asking for details about the error and discussing the solution
with him.
C. Thank the programmer, saying the program will be checked but asking him to check
that the error is not in his program.
D. Thank the programmer, indicating there is not time to correct the code and requesting
that he do so.
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=111
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 112
Which of the following declarations uses the LEAST memory? DCL 1 S1 ALIGNED, 2 A
CHAR(3), 2 B BIN FIXED(31), 2 C DEC FIXED(5), 2 D BIN FIXED(15); DCL 1 S2
UNALIGNED, 2 A CHAR(3), 2 B BIN FIXED(31), 2 C DEC FIXED(5), 2 D BIN
FIXED(15); DCL 1 S3 ALIGNED, 2 B BIN FIXED(31), 2 A CHAR(3), 2 D BIN
FIXED(15), 2 C DEC FIXED(5); DCL 1 S4 ALIGNED, 2 D BIN FIXED(15), 2 A
CHAR(3), 2 B BIN FIXED(31), 2 C DEC FIXED(5);
A. S1
B. S2
C. S3
D. S4
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=112
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 113
Which of the following techniques, if any, can be used to parallelize a PL/I program?
QUESTION: 114
A mainframe project is behind schedule and a project leader has only one copy of a PC-based
PL/I compiler available for distribution to team members who are all eager to use it. Optimally,
to whom should it be provided first?
QUESTION: 115
The following coding standards are enforced at a programming shop: * All procedures must
include a comment describing its function * All automatic variables must be explicitly
initialized when declared * No nested IF statements (implement as SELECT) Considering the
following code, how many coding standard violations exist? CALL P1(1); /* ------- proc p1------ */ P1: PROC(l); DCL I BIN FIXED(31); DCL (J,K) BIN FIXED(31) INIT(0); IF I = 1
THEN IF J = 2 THEN K = 3; ELSE K = 4; ELSE K = 5; END;
A. 1
B. 2
C. 3
D. 4
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=115
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 116
Given the following code, which is the only valid way to convert Q to P? DCL Q OFFSET;
DCL P POINTER; DCLX CHAR(100)BASED; DCL A AREA(6000); ALLOC X SET(Q)
IN(A);
A. P = Q;
B. P = POINTER(Q,A);
C. P = POINTERVALUE(Q);
D. P = ADDR(A) + Q;
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=116
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 117
In which of the following cases is a performance analyzer tool NOT useful?
QUESTION: 118
A compiler listing annotated with execution counts per statement helps identify all of the
following EXCEPT
QUESTION: 119
The Senior Vice President of the organization is onsite for a one day visit. She has asked for a
meeting with the team lead to understand the status of the project. Which of the following is the
most appropriate action for the team lead to take?
QUESTION: 120
A dummy argument is NOT created when a routine is called in which of the following
situations?
QUESTION: 121
In the following example, what value will be written to SYSPRINT, if anything, by the PUT
statement in PGM_A? PGM_A: PROC; DCL INPARM CHAR (12) INIT(FIRST CALL? );
DCL P_OUT PTR; DCL OUTPARM CHAR (10) BASED (P_OUT); DCL PGM_B ENTRY
(CHAR(12),PTR) EXTEPNAL; CALL PGM_B (INPARM,P_OUT); IF OUTPARM =
YES THEN DO; INPARM = FOLLOW ON; CALL PGM_B (INPARM,P_OUT); END;
ELSE DO; INPARM = NORMAL CALL; CALL PGM_B (INPARM,P_OUT); END;
PUT SKIP LIST(OUTPARM); END; PGM_B: PROC(INPARM,P_OUT); DCL INPARM
CHAR (12); DCL P_OUT PTR; DCL OUTPARM CHAR (12) STATIC INIT(); P_OUT =
ADDR(OUTPARM); IF INPARM = FIRST CALL? THEN OUTPARM = YES; ELSE
IF OUTPARM = THEN OUTPARM = FIRST CALL; END;
A. FIRST CALL
B. YES
C. blanks
D. The results are unpredictable.
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=121
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 122
ltthere is a direct read access to a data objectwith a unique key (e.g., DB2-SELECT, IMS-GU,
...),which otthe following return codes is possible?
QUESTION: 123
It becomes apparent that the deadline to implement and test all the functions required for an
application is at risk. Which of the following is the best course of action?
QUESTION: 124
What characterizes the hierarchical data model with respect to data access?
QUESTION: 125
What will be printed, if anything, to SYSPRINT after executing the following code? DCL A
FIXED CONTROLLED; DCL P PTR; DCL X FIXED BASED(P); ALLOC A; A = 1;
ALLOC A; A = 2; P = ADDR(A); ALLOC A; A = 3; P = ADDR(A); ALLOC A; A = 4;
FREE A; FREE A; PUT DATA(X);
A. 2
B. 3
C. 4
D. The results are undefined.
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=125
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 126
Given the following declaration, which code does NOT initialize C completely? DCL 1 A, 2
B DIM (0:9), 3 C DIM (5) FIXED BIN (31), 3 D CHAR (100) VAR;
QUESTION: 127
A. Is intended for single use only and must be refreshed from disk before it can be
invoked again
B. Must contain the necessary logic to reset control variables and data areas at entry or
exit and a second task may not enter the module until the first task has finished
C. Is designed for concurrent execution by multiple tasks
D. All or part of it may be replaced at any time by the operating system
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=127
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 128
Given the following code, which set of statements will insert the new element into the doublylinked list after the element pointed to by P? DCL 1X BASED, 2 FORWARD POINTER,
2 BACKWARD POINTER, 2 DATA FIXED BIN (31); ALLOC X SET(Q);
QUESTION: 129
Given the following statements, where will the variables A, B and C be allocated? DCL A
FIXED; DCL B CHAR(80) BASED(P); DCL C CHAR(1000) CONTROLLED; DCL D
AREA(1000); DCL P PTR STATIC; ALLOC C; ALLOC B IN(D);
QUESTION: 130
What will be printed to SYSPRINT after the following statements? DCLZZ9 PlC ZZ9
INIT(-1); DCL A CHAR(10) INIT(LOW(10)); DCL B CHAR(10) INIT(PL/l); SELECT;
WHEN(A = LOW(12)) PUT(CASE 1); WHEN(SUBSTR(B11.3) = PL/I) PUT(CASE
A. CASE 1
B. CASE 2
C. CASE 3
D. CASE 4
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=130
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 131
Which of the following compile list sections would be used to find the location of a static
variable in a dump?
A. Attribute/Xref Table
B. Source Listing
C. Table of Offsets and Statement Numbers
D. Storage Offset Listing
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=131
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 132
Which of the following runtime options should be reviewed when attempting to improve
performance in a PL/I program?
QUESTION: 133
Given the following pseudocode inside a loop, where should the COMMIT action be placed
assuming that there is always a one-to-many relationship between header and detail tables? 1
Find header row 2 IF found 3 Update header row 4 Find detail row 5 IF found THEN 6
Update detail rows 7 ELSE 8 ENDIF 9 ENDIF
A. Afterline 3
B. Afterline 6
C. Afterline 8
D. After lines 3, 8, and 9
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=133
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 134
Requirement Copy a dataset of record length 100 to another dataset. If the following code does
not fulfill the requirement above, which is the most likely reason? DCL DDIN FILE RECORD
INPUT; DCL DDOUT FILE RECORD OUTPUT; DCL INSTRUC CHAR(100); DCL
EOF_IN BIT(1) INIT(0B); ON ENDFILE(DDIN) EOF_IN = 1B; READ FILE(DDIN)
INTO(INSTRUC); DO WHlLE(^EOF_IN); WRITE FILE(DDOUT) FROM(INSTRUC);
READ FILE(DDIN) INTO(INSTRUC); WRITE FILE(DDOUT) FROM(INSTRUC); END;
A. The code does not fulfill the requirement because too many records will be written to
the output dataset, except when the input dataset is empty.
B. The code does notfulfill the requirement because the input structure is the same as
the output structure.
C. The code does notfulfill the requirement because the OPEN statements are missing.
D. The code fulfills the requirement.
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=134
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 135
What happens after executing the following code? DCL OUTFILE FILE RECORD OUTPUT;
DCLP PTR; DCL I BIN FIXED(31); DCL A BIN FIXED(31) BASED(P); DO I = 1 TO 10;
LOCATE A FILE(OUTFILE) SET(P); A = I; END; CLOSE FILE(OUTFILE);
QUESTION: 136
If the PROC name is less than 8 characters, what ENTRY point should be specified for a PL/I
routine which will be FETCHed?
A. PLISTART
B. CEESTART L
C. The PROC name
D. The PROC name followed by a 1
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=136
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 137
Given the lollowing declarations, what statement will raise STRINGSIZE condition if enabled?
DCLA_STR CHAR (100) VARYING; DCLB_STR CHAR(10) STATIC; DCL C_STR
CHAR (100);
A. A_STR = B_STR;
B. C_STR = B_STR;
C. SUBSTR(C_STR, 92) = B_STR;
D. C_STR = A_STR;
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=137
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 138
Given the following code, which call will pass a dummy argument? PROG: PROC
OPTIONS(MAIN); DCL SUM01 DEC FIXED(5,0) INIT (7); DCL SUM02 DEC
FIXED(9,0) INIT (999); CALL SUBA(SUM01, SUM02); CALL SUSB(SUM01,
SUM02); CALL SUBC(SUM01, SUM02); CALL SUBD(SUM01, SUM02); SUBA
PROC( PRM1, PRM2); DCL PRM1 DEC FIXED (5,0) BYVALUE, PRM2 DEC FIXED
(9,0); END SUBA; SUBB: PROC( PRM1, PRM2); DCL PRM1 DEC FIXED (5,0),
PRM2 DEC FIXED (9,0); END SUBD; SUBC: PROC( PRM 1, PRM2); DCL PRM1
BIN FIXED (15,0), PRM2 DEC FIXED (9,0); END SUBC; SUBD: PROC( PRM 1,
PRM2); DCL PRM1 DEC FIXED(5,0) BYADDR, PRM2 DEC FIXED (9,0) SYADDP;
END SUBD; END PROG;
A. Call to SUBA
B. CaII to SUBB
C. CaII to SUBC
D. CaII to SUBD
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=138
-------------------------------------------------------------------------------------------------------------------------------------
QUESTION: 139
Given the following code, what will happen? DCL(K, L) FIXED DEC (1); K= 1; L = 2;
PUT SKIP LIST (12+K/L);
QUESTION: 140
Given the following declaration for X: DCLX FIXED DEC (3) INIT (123); If Y is declared as
CHAR, what should its minimum length be to preserve the value 123 if these statements are
executed? Y = X; X =Y;
A. 3
B. 4
C. 5
D. 6
Answer: http://www.twpass.com/twpass.com/exam.aspx?ecode=000-042&qno=140
-------------------------------------------------------------------------------------------------------------------------------------