QBASIC program to print cube of first 50 natural numbers
CLS
FOR I = 1 TO 50
PRINT I ^ 3,
NEXT I
END
USING SUB
DECLARE SUB SERIES
CLS
CALL SERIES
END
SUB SERIES
FOR I = 1 TO 50
PRINT I ^ 3,
NEXT I
END SUB
CLS
FOR I = 1 TO 50
PRINT I ^ 3,
NEXT I
END
DECLARE SUB SERIES
CLS
CALL SERIES
END
SUB SERIES
FOR I = 1 TO 50
PRINT I ^ 3,
NEXT I
END SUB
0 Comments