Cobol : Perform

  •  cobol
  • Berikut merupakan program cobol untuk menampilkan output pada procedure lain yang di panggil menggunakan perform.

    Programnya :

    (perform) download
         IDENTIFICATION DIVISION.
          PROGRAM-ID. LA_IVANS_PERFORM.
          AUTHOR. IVANS.
    
          ENVIRONMENT DIVISION.
    
          DATA DIVISION.
          WORKING-STORAGE SECTION.
          77 JAWAB PIC 9.
          
          PROCEDURE DIVISION.
          MULAI.
              PERFORM PROCEDURE-A.
              DISPLAY "SELAMAT BELAJAR".
              PERFORM PROCEDURE-B.
              PERFORM PROCEDURE-A.
              STOP RUN.
          PROCEDURE-A.
              DISPLAY "******************".
              DISPLAY "==================".
          PROCEDURE-B.
              DISPLAY "DAN SEMOGA SUKSES".
    

    Hasil Output nya :

    Comments