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 |
What is the difference between Structured COBOL Programming and Object Oriented COBOL programming?
0 Answers TryTechnicals Pvt Ltd,
after udatingg first 110 rows, my job abends. now how do i change my cobol program so that when i restart the Job it will start updating from 111th row ( i.e in next run I di=ont want to update those 110 rows which are already been updated in the first run before job abend)
can anyone explain me the concept of COMP-4 PLEASE??
How will you find the currepted records in a file
Consider the following: 77 W-NUM PIC 9 VALUE 0 ------ MOVE 1 TO W-NUM PERFORM PARA-X UNTIL W-NUM > 9. ------ PARA-X ADD 1 TO W-NUM How many times PARA-X is executed ?
what happens if we wont give timestamp in precompilation process ?
Difference between ps, esds
why we are using set in searchall?
In COBOL "BEFORE" advancing is there or not ?
how many maximum no of variables can be declared in linkage section ?
) How do u handle errors in BMS macro?
In an EVALUATE statement, can I give a complex condition on a when clause?