Suppose a program has the following code. What will be the
output?
MAIN-PARA.
DISPLAY 'MAIN-PARA'
PERFORM SECTION-A.
STOP RUN.
SECTION-A.
PARA-A1.
DISPLAY 'SECTION A PARA A1'.
PARA-A2.
DISPLAY 'SECTION A PARA A2'.
Answers were Sorted based on User's Feedback
Answer / deependra
The output is as follow:-
MAIN-PARA
SECTION A PARA A1
SECTION A PARA A2
| Is This Answer Correct ? | 24 Yes | 1 No |
Answer / wairagade
Output = MAIN-PARA
See the Main-Para. the flow is like , it will display MAIN-
PARA text and then perform SECTION-A in which nothing is
coded, it will give control back to OS.
If PERFORM SECTION-A thru PARA-A2
Then
O/P
MAIN-PARA
SECTION A PARA A1
SECTION A PARA A2
Please correct me if I stated wrong
| Is This Answer Correct ? | 3 Yes | 3 No |
The output is :
---------------
MAIN-PARA
SECTION A PARA A1
SECTION A PARA A2
Because, There is no THRU command in PERFORM statement. So
it will execute still it reaches the 'EXIT' command or it
will perform the full section or until the next section
reaches.
| Is This Answer Correct ? | 0 Yes | 1 No |
we can use set true for condition names.. similarly can we code set to false in cobol pgm? will it work?
is this below syntax correct? CALL 'subprg' using A,B Please help
I have sequential file recl 1000 i want to add another 15 bytes to it. The record length should not change..How?
Which division and paragraphs are mandatory for a COBOL program?
Did anybody attend the walkin of TCS on 31st July in Gurgaon for any technology,If u have completed 3 round i.e till the HR round,have u received the Offer letter yet? Please let me know.Thanks.
copy 100 records without using ibm utilities
How can you get the ksds file records into your cobol program?
for an INITIALIZE and what keyword allows for an override of the default.
what are the diferences b/w sub-script and index?
How to know whether the module is dynamical or statistical?
What is the difference between next sentence and continue in cobol programing language?
what are decleratives in cobol?