Logo 
Search:

Cobol Articles

Submit Article
Home » Articles » Cobol » Homework HelpRSS Feeds

PROGRAM DISPLAYS ON THE PRINTER A VALUE COMPUTED FROM A DIVIDE OPERATION QUOTIENT IS PLACED INTO A DIFFERENT FIELD

Posted By: Bourke Fischer     Category: Cobol     Views: 1580

WRITE A PROGRAM DISPLAYS ON THE PRINTER A VALUE COMPUTED FROM A DIVIDE OPERATION QUOTIENT IS PLACED INTO A DIFFERENT FIELD.

Code for PROGRAM DISPLAYS ON THE PRINTER A VALUE COMPUTED FROM A DIVIDE OPERATION QUOTIENT IS PLACED INTO A DIFFERENT FIELD in Cobol

       IDENTIFICATION DIVISION.

       PROGRAM-ID. PROG414.
       ENVIRONMENT DIVISION.

       CONFIGURATION SECTION.

       SPECIAL-NAMES.

           PRINTER IS PRINTER-DISPLAY.
       DATA DIVISION.
       01  W005-DIVISOR                    PIC 9   VALUE 2.  

       01  W005-DIVIDEND                   PIC 99  VALUE 12.

       01  W005-QUOTIENT                   PIC 9.

       PROCEDURE DIVISION.

       PRINT-COMPUTED-VALUE.
           DIVIDE W005-DIVISOR INTO W005-DIVIDEND GIVING W005-QUOTIENT.
           DISPLAY "PROGRAM PROG412: THE QUOTIENT OF 12 / 2 IS:"
                                       UPON PRINTER-DISPLAY.
           DISPLAY W005-QUOTIENT       UPON PRINTER-DISPLAY.
           STOP RUN.
  
Share: 



Bourke Fischer
Bourke Fischer author of PROGRAM DISPLAYS ON THE PRINTER A VALUE COMPUTED FROM A DIVIDE OPERATION QUOTIENT IS PLACED INTO A DIFFERENT FIELD is from Frankfurt, Germany.
 
View All Articles

Related Articles and Code:


 
Please enter your Comment

  • Comment should be atleast 30 Characters.
  • Please put code inside [Code] your code [/Code].

 
No Comment Found, Be the First to post comment!