Wednesday, October 16, 2019

86. Qbasic Program to display 12345, 1234, 123, 12, 1

86. Write a sub procedure to display 12345, 1234, 123, 12, 1
DECLARE SUB DISP( )
CLS
CALL DISP
END
SUB DISP ( )
FOR I = 5 TO 1 STEP -1
    FOR J = 1 TO I
        PRINT J;
    NEXT J
    PRINT
NEXT I
END SUB

No comments:

Post a Comment