Coding input-output statements for line-sequential files

Code the input and output statements shown below to process a line-sequential file.

OPEN
To initiate the processing of a file.

You can open a line-sequential file as INPUT, OUTPUT, or EXTEND. You cannot open a line-sequential file as I-O.

READ
To read a record from a file.

With sequential processing, a program reads one record after another in the same order in which the records were entered when the file was created.

WRITE
To create a record in a file.

A program writes new records to the end of the file.

CLOSE
To release the connection between a file and the program.

related references  
OPEN statement (Enterprise COBOL for z/OS® Language Reference)  
READ statement (Enterprise COBOL for z/OS Language Reference)  
WRITE statement (Enterprise COBOL for z/OS Language Reference)  
CLOSE statement (Enterprise COBOL for z/OS Language Reference)