1
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 1 year has passed since last update.

【COBOL】COBOLのCALL・USING・LINKAGE わかりやすく

Last updated at Posted at 2022-05-25

コード

IDENTIFICATION DIVISION.
PROGRAM-ID. MAIN.
DATA DIVISION.
  WORKING-STORAGE SECTION.
    01 NUM PIC 9(3) VALUE 111.
PROCEDURE DIVISION.
CALL "SUB" USING NUM.
DISPLAY NUM.
END PROGRAM MAIN.


IDENTIFICATION DIVISION.
PROGRAM-ID. SUB.
DATA DIVISION.
  LINKAGE SECTION.
    01 NUM    PIC 9(3).
PROCEDURE DIVISION USING NUM.
MULTIPLY  NUM  BY  2  GIVING  NUM.
END PROGRAM SUB.


結果

222
1
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?