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
seraphim [82]
2 years ago
13

You are making a game! The player tries to shoot an object and can hit or miss it. The player starts with 100 points, with a hit

adding 10 points to the player’s score, and a miss deducting 20 points. Your program needs to take 4 action results as input ("hit" or "miss"), calculate and output the player’s remaining points.
Computers and Technology
1 answer:
Anni [7]2 years ago
3 0

The program illustrates the use of loops and conditions.

Loops are used for repetitions, while conditions are used to make decisions

The game program in Python, where comments are used to explain each line is as follows:

#This initializes the point to 100

point = 100

#The following loop is repeated 4 times

for i in range(4):

   #This gets the current action

   action = input("Hit or Miss: ")

   #This following if statement calculates the point

   if action.lower() == "hit":

       point+=10

   else:

       point-=20

#This prints the calculated point

print(point)

Read more about loops and conditions at:

brainly.com/question/14284157

You might be interested in
SOMEONE PLEASE HELP ME PLEASE HELP ME WITH THIS!!!!!
zavuch27 [327]

Answer:

The last one

Explanation:

I hope this is correct and have a great day

7 0
2 years ago
Read 2 more answers
This is a graded practice activity. This is not an actual quiz.
Lerok [7]

Answer:

0

Explanation:

x=27

y=5

22+(27-5)

22+(22)

0

8 0
1 year ago
Programming in https<br>​
kakasveta [241]
What?? explain your question
3 0
2 years ago
HELPPP!!! ASAP *What are the purposes of a good web page?*
Brrunno [24]

I would say functional and straightforward

4 0
3 years ago
What type of activities are performed with the help of the software used in hospitals?
faust18 [17]

Answer:

Xrays, Ultrasounds, managing patient records, communicating with colleagues, etc.

7 0
2 years ago
Read 2 more answers
Other questions:
  • In Linux Operating System, what file extension is used forexecutable files?
    6·1 answer
  • Your network employs basic authentication that centers on usernames and passwords. However, you have two ongoing problems. The f
    13·1 answer
  • You recently discovered that Marketing1 can connect to Admin1, and Admin1 can connect to Marketing1, but neither of these comput
    11·1 answer
  • 4. UPS stands for Uninterrupted Power Supply . (Yes /no
    11·1 answer
  • WILL GIVE BRAINLIEST!!!!!!!
    10·2 answers
  • How do news organizations primarily create revenue?
    12·2 answers
  • PACIFIC NORTHWEST
    10·1 answer
  • Delete temp or %temp% files in Windows 10 is safe and, can it help boost up your PC fps?
    5·1 answer
  • nts/viewer/classes/289ef1a5d7c341c284010 Select the compound inequality shown on the graph. 5 4 3 2 1 0 1 2 를 4​
    6·1 answer
  • Pleaseeeee helpppppppp​
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!