You're about to loop through a list to add up all its numbers. What should you set the running total variable to before the loop starts?
A program loops through the list [4, 7, 2, 9] and keeps a running total, starting at 0. What is the total after the loop finishes?
Answer: ______________
Before totalling a list, what should the running total start at?
A counting loop adds 1 only when an item passes the test.
Circle one: True False
A loop counts how many items in the list [-3, 5, -1, 8, -9, 2] are negative, starting the counter at 0. What is the counter after the loop finishes?
In the list [3, 8, 15, 22, 6, 19], how many numbers are greater than 10?
Answer: ______________
A loop adds up every number in the list [15, 3, 8, 12, 5], starting the running total at 0. What is the final total?
Answer: ______________
Find the largest of 12, 45, 7, 39, 45 and 3 by checking each once.
Answer: ______________
A friend starts best-so-far at 0 for -8, -2, -15 and -4. What will the loop claim?
A loop sums the numbers in the list [1, 2, 3, 4, 5, 6, 7, 8, 9, 10], starting the running total at 0. What is the final total?
Answer: ______________