Wednesday, October 16, 2019

79. Qbasic program to print the multiplication table of any input number up to tenth terms.


79.      Write a program using a SUB procedure module to print the multiplication table of any input number up to tenth terms. [SEE 2075 S2]

DECLARE SUB MUL (N)
CLS
INPUT "ENTER ANY NUMBER"; N
CALL MUL (N)
END
SUB MUL (N)
FOR I = 1 TO 10
PRINT N; "X"; I; "="; N * I
NEXT I
END SUB


4 comments: