Ask Question

The Counter Pattern

This pattern is one of the most important ones in all of programming.

It is used to increase the value of a variable by 1. You might call it the counter pattern since it can be used to make a variable that counts up. You'll use this pattern a lot, especially with the draw loop. Let's see what that looks like.

Do This

This program creates a variable counter and then uses the counter pattern to make it count up. When you run the program what do you think you'll see on the screen?

Read the program and make a prediction of what the output will be.

Run the program to check your prediction.

Discuss with a neighbor. Can you explain what you observed?

+3
Answers (1)
  1. 22 March, 02:24
    0
    You'll probably see numbers counting up, like 1 2 3 4 ...
Know the Answer?
Not Sure About the Answer?
Find an answer to your question 👍 “The Counter Pattern This pattern is one of the most important ones in all of programming. It is used to increase the value of a variable by ...” in 📗 Computers & Technology if the answers seem to be not correct or there’s no answer. Try a smart search to find answers to similar questions.
Search for Other Answers