fork download
  1. IDENTIFICATION DIVISION.
  2. PROGRAM-ID. ADDITION.
  3.  
  4. DATA DIVISION.
  5. WORKING-STORAGE SECTION.
  6. 01 NUM1 PIC 9(5) VALUE 0.
  7. 01 NUM2 PIC 9(5) VALUE 0.
  8. 01 TOTAL PIC 9(6) VALUE 0.
  9.  
  10. PROCEDURE DIVISION.
  11. DISPLAY "Enter first number: ".
  12. ACCEPT NUM1.
  13.  
  14. DISPLAY "Enter second number: ".
  15. ACCEPT NUM2.
  16.  
  17. ADD NUM1 TO NUM2 GIVING TOTAL.
  18.  
  19. DISPLAY "The sum is: " TOTAL.
  20.  
  21. STOP RUN.
  22.  
Success #stdin #stdout 0s 5288KB
stdin
1;2
stdout
Enter first number: 
Enter second number: 
The sum is: 000000