Q BASIC program to display the sum of first 5 odd numbers



  • A program to display the sum of first 5 odd numbers



         CLS

 

          LET C=1


          PRINT C


          LET A= A+C


          L:LET C =C+2


         LET A= A+ C


         PRINT C


        IF C<9 THEN GOTO L


        PRINT "SUM=", A


        END





     

          

          

Comments

Popular posts from this blog

Introduction to Commands in Q basic

A program to accept any number and display its multiplication table