25 lines
699 B
COBOL
25 lines
699 B
COBOL
IDENTIFICATION DIVISION.
|
|
PROGRAM-ID. mult.
|
|
AUTHOR. GR.
|
|
* Ce programme effectue la multiplication de 2 entiers
|
|
*
|
|
|
|
ENVIRONMENT DIVISION.
|
|
DATA DIVISION.
|
|
|
|
WORKING-STORAGE SECTION.
|
|
77 Num1 PIC 999 VALUE ZERO.
|
|
77 Num2 PIC 999 VALUE ZERO.
|
|
77 Res PIC Z(5)9.
|
|
|
|
PROCEDURE DIVISION.
|
|
PROGRAMME SECTION.
|
|
P1.
|
|
DISPLAY "Taper le 1er nombre (<999) : " WITH NO ADVANCING.
|
|
ACCEPT Num1.
|
|
DISPLAY "Taper le second nombre : " WITH NO ADVANCING.
|
|
ACCEPT Num2.
|
|
MULTIPLY Num1 BY Num2 GIVING Res.
|
|
DISPLAY "Résultat = " Res.
|
|
STOP RUN.
|