REM Display multiples of 3
FOR I=3 TO 30 STEP_____
PRINT I
NEXT I
(e) What should be the step value in the following code?
Answers
Answered by
7
Answer:-
In the given qbasic code, the value of step will be 3.
This is because difference between multiples of 3 is 3.
So, if the code is like,
FOR I=3 TO 30 STEP 3
PRINT I
NEXT I
Then, output will be,
3
6(3+3)
9(3+3+3)
....... and this will continue till 30.
So, the required value is 3.
Answered by
0
Answer:
Step value will be 3
Code:
REM Display multiples of 3
REM Display multiples of 3FOR I=3 TO 30 STEP_____
REM Display multiples of 3FOR I=3 TO 30 STEP_____PRINT I
REM Display multiples of 3FOR I=3 TO 30 STEP_____PRINT INEXT I
Similar questions
Social Sciences,
3 months ago
Physics,
6 months ago
English,
6 months ago
Political Science,
11 months ago
Geography,
11 months ago