Which of the following statements can be used for looping in BASIC?

Assessment: WAEC SSCE - Computer Studies - 2017 (Objective) Subject: Computer Studies

Question 1 Report

Which of the following statements can be used for looping in BASIC?       

Answer Details

The statement that can be used for looping in BASIC is "FOR ... NEXT". The FOR loop is used to execute a set of statements a specified number of times, while the NEXT statement is used to terminate the FOR loop. The general format for the FOR loop is:


FOR variable = start_value TO end_value [STEP step_value]
    [statements]
NEXT variable

The variable is set to the start value, and the loop executes until it reaches the end value, incrementing by the step value (if provided) each time. The statements inside the loop are executed for each iteration of the loop. The NEXT statement is used to indicate the end of the loop and to specify the variable that is being incremented.

Download The App On Google Playstore

Everything you need to excel in your exams

Green Bridge CBT Mobile App
Personalized AI Learning Chat Assistant
200,000+ Exam Questions Across IGCSE, JAMB, WAEC & NECO
Over 3,900 Lesson Notes
Offline Support - Learn Anytime, Anywhere
Green Bridge Timetable
Literature Summaries & Potential Questions
Track Your Performance & Progress
In-depth Explanations for Comprehensive Learning