7th Class Computers Science Programming Concepts Question Bank Programming in QBASIC

  • question_answer
    What will be the output of the given QBASIC codes?
    Code A Code B
    FOR I = 1 TO 5 STEP 2 FOR I =1 TO 5 STEP 1
    PRINT I PRINT I
    NEXT I I=I+1
      NEXT I
     

    A)
    Both will print
    1
    3
    5

    B)
    Code A Code B
    1 1
    3 2
    5 3
      4
      5

    C)
    Code A Code B
    1 1
    3 2
    5 4

    D)
    Code A Code B
    1 1
    2 3
    3 5
    4  
    5  

    Correct Answer: A

    Solution :

    Not Available  


You need to login to perform this action.
You will be redirected in 3 sec spinner