QUESTION IMAGE
Question
you need to write a program that has karel move 6 times and then put a ball. which control structure do you need to use? options: for loop, while loop, if statement, if/else statement, none of these
Brief Explanations
A for loop is used when the number of repetitions is known in advance. Here, Karel needs to move exactly 6 times, a fixed number of iterations. While loops are for conditional, unknown repetitions; if/if-else are for conditional branching, not repeated actions.
Snap & solve any problem in the app
Get step-by-step solutions on Sovi AI
Photo-based solutions with guided steps
Explore more problems and detailed explanations
For loop