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
Rom4ik [11]
2 years ago
10

in python i wrote a function where if the user inputs a certain word the function repeats over again, since the function aaks fo

r the word the end of the function, therotically the function can repeat infinte times. Now my question is, how can i find out how many times the function was repeated. i need to know how many times the function repeated in order to do a percentage calculation, can someone tell me, how i can find how many times the function was repeated ?
Computers and Technology
1 answer:
Colt1911 [192]2 years ago
4 0
Check out the counter set
You might be interested in
Mrs. Patel uses a computer program to balance her checkbook. Which of the following best explains how the
Alexandra [31]

Answer:

c it reduces errors

Explanation:

Instead of Mrs.Patel doing it she has an online program made for checks to do it for her.

6 0
3 years ago
What port number is the web server listening on for the web request?
Veronika [31]
80 for HTTP, 443 for HTTPS
8 0
3 years ago
What was the basic invention that has evolved into the modern automobile?
anygoal [31]

Answer:

I would say Henry Ford's invention; the Ford car company, since we still have Ford cars running nowadays.

Explanation:

3 0
3 years ago
the impact of the global digital divide. According to the authors, countries that lag behind the rest of the world’s ICT capabil
kvasek [131]

Answer:

hi

Explanation:

5 0
2 years ago
Given an array temps of double s, containing temperature data, compute the average temperature. Store the average in a variable
Ket [755]

Answer:

#include <iostream>

using namespace std;

// average function

void average(double arr[], int n) {

double total = 0;

double avgTemp;

for (int i = 0; i < n; i++)

{

 // find temperatures total

 total = total + arr[i];

}

// find average

avgTemp = total / n;

cout << "\nAverage Temperature = " << avgTemp << endl;

}

// print temps[] array

void printArray(double arr[], int n) {

for (int i = 0; i < n; i++)

{

 cout << arr[i] << "   ";

}

}

int main() {

int const k = 5;

double temps[k];

// temperature value

double tempValue;  

// Enter 5 temperatures of your choice

for (int i = 0; i < k; i++)

{

 cout << "Enter Temperature value " << i+1 << ": ";

 cin >> tempValue;

 temps[i] = tempValue;

}

// Function call to print temps[] array

printArray(temps, k);  

// Function call to print average of given teperatures

average(temps, k);        

return 0;

}

Explanation:

• Inside main(), int constant k is created to set the maximum size of array temps[].

• tempValue of  type double takes value at a given index of our temps[] array.

• the for loop inside main() is used to get tempValue from the user and store those values in our array temps[].

• after that printArray() function is called. to pass an array to a function it requires to perimeters 1) name of the array which is temps in our case. 2) maximum number of the index which is  k.

• note the syntax of void average(double arr[], int n). Since we are passing an array to the function so its formal parameters would be arr[] and an int n which specifies the maximum size of our array temps[].

6 0
3 years ago
Other questions:
  • A user deletes a message from a mailbox while on a desktop. What happens to the email message on the user's synchronized devices
    13·2 answers
  • Write a program whose input is two integers and whose output is the two integers swapped. Ex: If the input is: 3 8 then the outp
    12·1 answer
  • man who is colorblind marries a woman who has normal color vision and is not a carrier of color blindness. If this couple has a
    15·1 answer
  • Thank you very much for your email. ...... was very interesting​
    15·1 answer
  • What should you do first when designing a program?
    5·2 answers
  • What are benefits of virtualizing servers ?
    5·1 answer
  • Write a function template that accepts an argument and returns its absolute value. The absolute value of a number is its value w
    11·1 answer
  • Describe the major elements and issues with system prototyping​
    7·1 answer
  • What command in cisco IOS allows the user to see the routing table
    5·1 answer
  • Bob The Penguin is a real you-tuber, and he plays Mine-craft. Who is his owner?
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!