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
77julia77 [94]
4 years ago
7

Exercise 8.1.9: Diving Contest Your school is hosting a diving contest, and they need a programmer to work on the scoreboard! Yo

ur job is to calculate each diver's total after the three judges hold up their individual scores. Write the function calculate_score which takes a tuple of three numbers from 0 to 10 and calculates the sum. A perfect dive is worth 30 points, a belly flop is worth 0. For example: calculate_score((10, 10, 10)) # => 30 calculate_score((9, 9, 6)) # => 24 can someone help?
Computers and Technology
1 answer:
vampirchik [111]4 years ago
4 0

Answer:

def calculate_score(theTuple):

    first, second, third = theTuple

    if first >= 0 and first <=10 and second >= 0 and second <=10 and third >= 0 and third <=10:

         print(first + second+third)

    else:

         print("Range must be 0 to 10")

Explanation:

This line defines the function

def calculate_score(theTuple):

This line gets the content of the function

    first, second, third = theTuple

The following if condition checks if the digits are in the range 0 to 10

    if first >= 0 and first <=10 and second >= 0 and second <=10 and third >= 0 and third <=10:

This calculates the sum

         print(first + second+third)

else:

If number is outside range 0 and 10, this line is executed

         print("Range must be 0 to 10")

You might be interested in
You learned that properly edited resumes are necessary for making a good impression on a university or a potential employer. Dis
beks73 [17]

Answer:

Resume is the important document for job seekers. As much as the resume is better, there is more chance to grab the job.

If the resume is poor, the employer may not call you for the interview.

Explanation:

Resume is the document that create and impression over the potential employer or university.

If someone have very good hard and soft skills, and does not mention all the skills in resume, then employer could not that skills that you may have. Because your resume is the document that represent you when you are not in front of the employer.  This is the first document, presented that, what  you are and how you are beneficial for the company.

<em>If your resume is poor it may cause that He cannot call you for the interview or not considered for that JOB.</em>

5 0
3 years ago
Read 2 more answers
Create a button to play the playlist <br><br> Java, netbeans
Pavel [41]
I'm not sure but maybe one of the two websites can help you
.
http://wiki.netbeans.org/MusicAppUsingRESTRemoting

https://mukeshscience.wordpress.com/2014/05/26/adding-audio-to-java/

6 0
4 years ago
Read 2 more answers
Oliver wants to send a report to his boss discussing the upcoming project. Which communication facility would he use to send a f
vladimir2022 [97]
I pretty sure email
5 0
4 years ago
Read 2 more answers
What is a massive, room-sized computer that process and store enormous amounts of bulk data and information?
kipiarov [429]

Answer:

Mainframe Computer

Explanation:

The Mainframe Computers are designed for bulk data processing with high speed and storing huge data that can't be performed by other regular PCs. They can run multiple instances of operating systems at the same time. They are used for application such as accounting, business transaction, information retrieval, airlines for the seat reservation and engineering computation.

7 0
3 years ago
Project managers have the overall responsibility for planning, executing, and completing a project. (3 points) True False
Kazeer [188]
True, project managers are responsible for all of those things.
4 0
3 years ago
Other questions:
  • Different project management steps are initiating, planning, executing, monitoring and controlling, and closing a project. Which
    9·1 answer
  • 1. What is the main factor that affects Earth’s average temperature?
    12·1 answer
  • Which of these has the LEAST impact on causing the phenomenon known as acid raid?
    8·2 answers
  • Dr. Robbins wants to know if there are different opinions regarding the value of public school education between Native American
    11·1 answer
  • An information system report is an example of...
    13·1 answer
  • Requests to access specific cylinders on a disk drive arrive in this order: 24, 20, 4, 40, 6, 38, and 12, and the seek arm is in
    10·1 answer
  • Using technologies increase the time needed to complete a task is beneficial
    5·1 answer
  • 1. Write a SELECT statement that returns these columns: The count of the number of orders in the Orders table The sum of the Tax
    12·1 answer
  • Identify the type of software that should be in main memory in order to use the keyboard? *
    14·1 answer
  • Given a list of integers. find the size of the list
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!