How to replace the GOTO statement in COBOL without changing
the structure of program. e.g. consider following code...
I.D.
E.D.
D.D.
P.D.
compute C = A + B.
GOTO para 100-display.
compute D = C - D.
GOTO 200-display.
some other logic......
........
GOTO 300-para.
......
......
GOTO 400-para.
Now I want to replacce all GOTO statements without
changing the structure and otput of program.
Answer Posted / krishnan a
Instead of GOTO we can use PERFORM noneed to go EVALUATE
also
compute C = A + B.
PERFORM 100-display.
compute D = C - D.
PERFORM 200-display.
some other logic......
........
PERFORM 300-para.
......
......
PERFORM 400-para.
| Is This Answer Correct ? | 8 Yes | 5 No |
Post New Answer View All Answers
There are 5 fields and 1000 records in a file. Unload it into an array. Write the syntax for declaration and how will you unload it.
What are the different rules of SORT operation?
What are the different rules for performing sort operation?
Can we redefine the field of x(200) to less than 200?
How do you reference the fixed block file formats from cobol programs
What is the default value(s) for an initialize and what keyword allows for an override of the default?
what happens if parmparameter passes zero bytes to the program
what is difference bt COND, REGION & TIME parameters at JOB & EXEC. give an exp.
explain sorting techniques in cobol program?
What is the problem of ordered sequential files access?
What is a SSRANGE and NOSSRANGE?
how do you reference the variable unblock file formats from cobol programs
When is inspect verb is used in cobol?
Hi pls anybody tell me about " ANALYSIS DOCUMENT PREPARATION AND ESTIMATION OF TASK " (in real time project)."I want to update a sequential file in my project" for that purpose i need both structures i mean analysis document and estimation of task.
What is amode(31)