최신 IBM certifications II C9050-041 무료샘플문제:
1. CORRECT TEXT
Given the following declarations, which code is always a valid way to test if the value of B is 7?
DCL P POINTER NIT (NULL());
DCL B FIXED BIN (31) BASED (P);
A) IF B ^ = 7 THEN; ELSE
PUT ('OK');
B) IF B = 7
THEN PUT ('OK');
C) IF P ^= NULL() ! B = 7
THEN PUT ('OK');
D) IF ^ = NULL() THEN IF B = 7 THEN
PUT ('OK');
2. CORRECT TEXT
Given the following code, how many times is the loop executed?
DCL NEGATIVE BIT (1) INIT ('0'B);
DCLIFIXED BIN (31) INIT (10);
DO WHILE (^NEGATIVE)
PUT (I);
I += 1;
IF I >= 0 THEN NEGATIVE = '0'B;
ELSE
NEGATIVE = '1'B;
END;
A) Less than 10 times
B) 10
C) More than 11 times
D) 11
3. Given the following code, the compiler will issue the message "RULES(NOLAXIF) requires BIT(1) expressions in IF, WHILE, etc." under the option RULES(NOLAXIF).
In order to fix this problem, the IF statement should be changed to:
A) IF BOOL(RC = 0,4,'0111'B) THEN
B) IF BIT(RC = 0 ! 4) THEN
C) IF RC =(0 ! 4) THEN
D) PPOC( RC);
DCL RC FIXED BIN(31);
IF RC = 0 ! 4 THEN
E) IF RC=(0 ! RC = 4 THEN
4. CORRECT TEXT
Under default condition enablement, what is the result of executing the following code?
DCLX CHAR(5) INIT('A1234');
DCL Y PlC '9999' INIT(0);
Y = X;
A) The value of Y is 1234.
B) STRINGSIZE would be raised.
C) The value of Y is A 123.
D) CONVERSION would be raised.
5. CORRECT TEXT
What has to be done, if anything, when the compiler warns that a variable may be uninitialized when used?
A) Make sure the variable has a valid content before using it.
B) Initialize the variable to blank.
C) Use the DFT(INITFILL) compiler option so the message will disappear.
D) Ignore the message.
질문과 대답:
질문 # 1 정답: D | 질문 # 2 정답: C | 질문 # 3 정답: C | 질문 # 4 정답: D | 질문 # 5 정답: A |