Program to print pattern using LEFT$
CLS
INPUT "Enter a string"; a$
c = LEN(a$)
FOR i = 1 TO c
    PRINT LEFT$(a$, i)
NEXT i
END


Program to print pattern using LEFT$
CLS
INPUT "Enter a string"; a$
FOR i = LEN(a$) TO 1 STEP -1
    PRINT LEFT$(a$, i)
NEXT i
END