
COBOL-ACCEPT and DISPLAY
Example of ACCEPT and DISPLAY
PROGRAM
IDENTIFICATION DIVISION.
; ; ; ;
PROGRAM-ID. PGM001.
AUTHOR. MAINFRAMEWIZARD.
DATA DIVISION.
WORKING-STORAGE SECTION.
01 VAR1 PIC 9(3) VALUE ZEROES.
PROCEDURE DIVISION.
10000-MAIN-PARA.
ACCEPT VAR1.
DISPLAY 'VARIABLE INPUT IS=' VAR1.
STOP RUN.
OUTPUT
VARIABLE INPUT IS=10
Click the +1 button below to share it with your friends and colleagues
Share this if you liked it!
Comments
Post new comment