Skip to Content
Custom Search

COBOL PERFORM THRU

 

COBOL PERFORM THRU
 
The following simple COBOL program depicts the use of 
PERFORM para
 
 
       IDENTIFICATION DIVISION.
       PROGRAM-ID. PGM012.
       AUTHOR. MAINFRAMEWIZARD.
       DATA DIVISION.
       WORKING-STORAGE SECTION.
       01 WS-SUB PIC 9(3) VALUE ZEROS.
       PROCEDURE DIVISION.
       10000-MAIN-PARA.
             PERFORM 20000-FIRST-PARA THRU 30000-THIRD-PARA
             DISPLAY 'DEPICTING PERFORM THRU BY MAINFRAMEWIZARD.COM'
             DISPLAY 'PARA NAME IS  10000-FIRST-PARA'
             STOP RUN.
       20000-FIRST-PARA.
             DISPLAY 'PARA NAME IS  20000-FIRST-PARA'.
       25000-SECOND-PARA.
             DISPLAY 'PARA NAME IS  25000-SECOND-PARA'.
       30000-THIRD-PARA.
             DISPLAY 'PARA NAME IS  30000-THIRD-PARA'
 
 
Output of the above program is as below
 
 
 
PARA NAME IS  20000-FIRST-PARA                                                                                           
PARA NAME IS  25000-SECOND-PARA                                                                                          
PARA NAME IS  30000-THIRD-PARA                                                                                           
DEPICTING PERFORM THRU BY MAINFRAMEWIZARD.COM                                                                            
PARA NAME IS  10000-FIRST-PARA                                                                                           

Comments

Post new comment

  • Allowed HTML tags: <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd>
  • Lines and paragraphs break automatically.

More information about formatting options

CAPTCHA
This question is for testing whether you are a human visitor and to prevent automated spam submissions.

Click the +1 button  below to share it with your friends and colleagues

 

Share this if you liked it!

 

Disclaimer



Who's online

There are currently 0 users and 28 guests online.
Dr. Radut | page