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
tino4ka555 [31]
3 years ago
8

Write a loop to populate the list user_guesses with a number of guesses. Each guess is an integer. Read integers using int(input

()).
Computers and Technology
1 answer:
antoniya [11.8K]3 years ago
6 0

Answer:

num_of_guesses = int(input())

user_guesses = []

for n in range(num_of_guesses) :

guess_value = int(input())

user_guesses.append(guess_value)

print("User guesses :", user_guesses)

Explanation:

Using python

Line 1 prompts the user to input the number of guesses he / she will like to make.

Line 2, initiates an empty list which will be used to store the numbers which will be guessed.

The for loop which uses the condition stated in line 1, that is, the user will only be able to make guesses based on the value enters into num_of_guesses

guess_value prompts user to enter a value which is added to the user_guesses list

The print statement, lists the numbers guessed by the user.

You might be interested in
Do software engineers save millions of dollars in usa
SCORPION-xisa [38]
Yes. They make a lot of money. So eventually after saving your Money, you will make a least 1 million dollars or more.
4 0
3 years ago
Some 3d printers work by controlling the exact locations where a liquid
kow [346]
Were a liquid what? id doesn't make any sense.
6 0
4 years ago
Write a loop that fills an array int values[10] with ten random numbers between 1 and 100. Write code for two nested loops that
zalisa [80]

Answer:

#include <iostream>

#include <cstdlib>

using namespace std;

int main() {

   int[] array = new int[10];

   int index = 0;

   while(index < array.size()){

           int number = (rand() % 100) + 1;

           for (int i = 0; i < 1; i++) {

               array[index] = number;

               cout<< "Position "<< index << "of the array = "<< number << endl;

               ++index;

           }

     }

}

Explanation:

The while loop in the source code loops over a set of code ten times, The for loop only loops once to add the generated random number between 1 and 100 to the array of size 10. At the end of the for loop, the index location and the item of the array is printed out on the screen. The random number is generated from the 'rand()' function of the C++ standard library.

7 0
3 years ago
What is the best way to use a prototype to better understand yolir audience?
9966 [12]
I would say A. Test it and receive feedback
6 0
2 years ago
Xavier wants to use a solver to find optimal solutions for a decision problem. What should he select as X in the series of click
Marta_Voda [28]

Answer:

The answer is "Analyze"

Explanation:

The term Analyze is the use of a machine or critical thinking to enable more effective management by companies and their information systems, in which the Xavier wishes to use a method for solving to find ideal decision-making strategies. Its object of the series analyses X selects, that's why the "Analyze " is correct.

7 0
4 years ago
Other questions:
  • Use ________ resolution when recording human speech in an audio file.
    14·1 answer
  • What is one important feature of an aup? 1. a list of all available courses. 2. a clear out line of the consequences of violatin
    12·2 answers
  • 110101111.11011 to decimal (base 10)
    6·1 answer
  • Explain the factors involved in selecting a routing protocol to be used on a network.
    12·1 answer
  • What should be used to clean LCD monitors? Liquid window cleaner Ammonia wipes Windshield washer liquid Antistatic monitor wipes
    15·1 answer
  • Lol who look at this so funny
    6·1 answer
  • Your boss is very skeptical about the idea of storing his files up in the cloud rather than on a local storage drive. He asks yo
    7·1 answer
  • You can minimize the Ribbon with a command contained on the _____.
    7·1 answer
  • Take the average of some numbers. Show all the numbers that are below average. You can assume that there will not be more than 2
    10·1 answer
  • How can random numbers in a range be generated in Java?.
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!