Basic Program To Print Sum of Square of First N Odd Numbers

REM SUM OF FIRST N ODD NOS., SUM OF SQU OF FIRST N ODD NOS..?
CLS
SUM = 0
FOR I = 1 TO 10
LET A = 2 * I – 1
LET A = A * A
LET SUM = SUM + A
PRINT A, SUM
NEXT I
PRINT ” SUM”; SUM
END

Please follow and like us:

Leave a comment