What is the output generated by the following code?
01 GRP-I.
05 SUBFLD1 PIC XX VALUE "AB".
05 FILTER PIC X(6) VALUE SPACES.
01 GRP-2 REDEFINED GRP-1.
05 SUB-FLD2 PIC XX.
05 SUB-FLD3 PIC XX.
05 FILTER PIC X(4).
IF SUB-FLD1 NOT = SPACES
DISPLAY "SUBFLD1"
MOVE "ABBCCD" TO GRP-1
IF SUB-FLD3 = SPACES
DISPLAY "SPACES"
ELSE
DISPLAY "SUBFLD3"
DISPLAY "END"
ELSE
DISPLAY "SPACES"
DISPLAY "END".
(a) SUBFLD1
SUBFLD3
END
(b) SPACES
END
(c) SUBFLD1
END
(d) SUBFLD1
SPACES
Answer Posted / muttaiah
I guess we will get Maxcc - 8 when we compile. Because
SUB-FLD1 is not declared anywhere here. If the field has to
be SUBFLD1 by typo mistake.
Then answer would be (a).
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What rules are to be followed while using the corresponding options?
Explain how you can characterize tables in cobol?
What are 77 levels used for?
What is the utilization of copybook in cobol?
how do you reference the esds vsam file formats from cobol programs
How to find out the closest prime number of an input number? I believe it has something to do with SEARCH and COBOL Linear Array.
In COBOL programming, what is PERFORM? What is VARYING?
In which area will you utilize 88 level items in cobol?
I have to write to a outfile where the number of records in that file should be the header of that file using IMS.. can anyone help me in this issue
How do you differentiate between cobol and cobol-ii?
What is the difference between comp and comp-3?
What are the rules of the move verb?
Differentiate cobol and cobol-ii. (Most of our programs are written in cobolii, so, it is good to know, how, this is different from cobol)?
How do you define a variable of comp-1 and comp-2?
what is difference between cobol and cobol/400