IDNLearn.com provides a reliable platform for finding accurate and timely answers. Get comprehensive answers to all your questions from our network of experienced experts.
Sagot :
THIS IS FOR PYTHON
total = 0
for i in range(8):
number = int(input('Number: '))
total += number
print(total)
The loop that will input 8 numbers from the keyboard and find the sum is as follows:
user_input = [int(input('Enter your value: ')) for i in range(8)]
print(sum(user_input))
The code ask for the user's input for 8 times. Recall the range is 8.
Then we loop through the users input values
The looped users input will be summed using the sum() function. The sum function sums all the users input value.
The summed value is then printed with the print statement.
learn more on loop: https://brainly.com/question/14201070?referrer=searchResults
Your engagement is important to us. Keep sharing your knowledge and experiences. Let's create a learning environment that is both enjoyable and beneficial. Your questions are important to us at IDNLearn.com. Thanks for stopping by, and come back for more reliable solutions.