1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Ahat [919]
2 years ago
9

considering that two variables counters and accumulators are important in loop design. What would be their purpose?

Computers and Technology
1 answer:
almond37 [142]2 years ago
5 0

Answer:

Counters are used to run the loop.

Accumulators are used to calculate and store the result.

Explanation:

In loops variables counters and accumulators are very important.The counter variable is used to increase the loop or move to the next iteration.

The accumulator variable is used to calculate and store the result of an operation in the loop.

For example:-

int i=0;

int sum=0;

while(i<7)

{

     sum=sum+i;

     i++;

}

In this while loop the counter variable is i and the accumulator variable is sum.Without the counter variable is not increased the loop will keep looping over the same value of i that is 0.

In the loop the accumulator variable sum is used to calculate the sum of integers form i=0 to 6.

You might be interested in
Which lighting direction is used to create silhouettes
Elena L [17]
The answer is backlighting
5 0
2 years ago
The marvelous attribute about the gaming industry is that you can create a game in several different programming languages to ma
LenaWriter [7]

Answer:

D syntax

Explanation:

The marvelous attribute about the gaming industry is that you can create a game in several different programming languages to make it more appealing to novice and advanced-level coders. Yet, the unique distinction is that every single programming language has its own syntax.

7 0
2 years ago
A fitness tracker can be classified as a wearable computer. true
Kay [80]
Depends, but I'd say false.
5 0
2 years ago
Define a function called strip_punctuation which takes one parameter, a string which represents a word, and removes characters c
DaniilM [7]

Answer:

punctuation_chars = ["'", '"', ",", ".", "!", ":", ";", '#', '@']

def strip_punctuation(strWord):

   for charPunct in punctuation_chars:

       strWord = strWord.replace(charPunct, "")

   return strWord

Explanation:

The function is defined with a single argument.

A for loop is ran to check each character of the the word.

If a punction mark is present as a character in the word, it is removed.

The same word is returned but without the punctuation marks.

8 0
3 years ago
Which word did alexander graham bell want adopted as a telephone greeting instead of hello.
Alik [6]

Answer:

I believe it was Ahoy.

Explanation:

I could be wrong though.

7 0
2 years ago
Read 2 more answers
Other questions:
  • Variable names may contain spaces and punctuation symbols. True False
    15·1 answer
  • In an oligopolistic market, consumer choice is?
    12·2 answers
  • What is the keyboard shortcut Ctrl+Z used for?
    14·2 answers
  • PLEASE HELP!<br> How do you "brainliest" an answer?
    13·2 answers
  • Www.microsoft.com is an example of this (two words) (last letter is e) and has to be (10 letters)
    10·1 answer
  • How to automatically ccleaner smartphone?
    10·1 answer
  • Data is?
    15·1 answer
  • You scan the network and find a counterfeit access point that is using the same SSID as an already existing access point. What i
    12·1 answer
  • Write an algorithm to find the average of three numbers: 10, 20, 30
    7·1 answer
  • Name any three areas of of application of excel.
    12·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!