Monday, October 21, 2019
QBasic Programming:
To Display: 1, 11, 111, 1111, 11111
CLS
A = 1
FOR I = 1 TO 5
PRINT A
A = A * 10 + 1
NEXT I
END
QBasic Programming:
To Display: 1, 22, 333, 4444, 55555
CLS
FOR I = 1 TO 5
FOR J = 1 O I
PRINT I;
NEXT J
PRINT
NEXT I
END
To Display: 1, 12, 123, 1234, 12345
CLS
FOR I = 1 TO 5
FOR J = 1 O I
PRINT J;
NEXT J
PRINT
NEXT I
END
Email ThisBlogThis!Share to TwitterShare toShare to Pio Display: 5, 10, 15, 20, ......... 10th terms
CLS
A = 5
FOR I = 1 TO 10
PRINT A
A = A + 5
NEXT I
END
To Display: 1, 4, 9, 16, ......... 10th terms
CLS
FOR I = 1 TO 10
PRINT I ^ 2
NEXT I
END
To Display: 1, 1, 2, 3, 5, ......... 10th terms
CLS
A = 1
B = 1
FOR I = 1 TO 10
PRINT A
C = A + B
A = B
B = C
NEXT I
END