Write a program to return bowling scores. The output should be same as given below: Bowling score
Fantastic news! We've Found the answer you've been seeking!
Question:
Write a program to return bowling scores. The output should be same as given below:
Transcribed Image Text:
Bowling score rules: each bowling game has 10 frames, and each frame has two balls. Knocking down a pin means earning a point, each ball can earn max 10 points or 0. Basically saying, the sum of two ball scores is the score for each frame and adding ten frames of them for final score. However, if the first ball gets 10 in a frame, it is called a strike and there is no 2nd ball for that frame, it will move to next frame automatically. The strike will make the score higher for the frame, it adds next two ball scores to the frame. If the sum of the 1st and the 2nd ball is 10 in a frame, it is called spare and it will add next ball score to the frame. Each ball score can NOT bigger than 10, or less than 0, and the sum of two ball score must less than or equals 10. Bowling score rules: each bowling game has 10 frames, and each frame has two balls. Knocking down a pin means earning a point, each ball can earn max 10 points or 0. Basically saying, the sum of two ball scores is the score for each frame and adding ten frames of them for final score. However, if the first ball gets 10 in a frame, it is called a strike and there is no 2nd ball for that frame, it will move to next frame automatically. The strike will make the score higher for the frame, it adds next two ball scores to the frame. If the sum of the 1st and the 2nd ball is 10 in a frame, it is called spare and it will add next ball score to the frame. Each ball score can NOT bigger than 10, or less than 0, and the sum of two ball score must less than or equals 10.
Expert Answer:
Answer rating: 100% (QA)
Python Program You can call this function with a list of integers representing the number of pins kn... View the full answer
Related Book For
Posted Date:
Students also viewed these programming questions
-
Write a program to compute word ladders where single-character substitutions have a cost of 1, and single-character additions or deletions have a cost of p > 0, specified by the user. As mentioned at...
-
Write a program to print Hello World 25 times without writing a single line in the main function except system(pause).
-
Write a program to input any amount of US dollars and convert the amount into any chosen world currency and output your results. Input the conversion factor for the currency of your choice.
-
Consider a situation wherein an exploration vehicle that has a mass of 250 kilogram on Earth ( gravityEarth = 9.8 m/s ) is sent to the Moon and planet Mars to explore their surfaces. What is the mass...
-
A 1.8-kg uniform rod is supported by a pin at O and a spring at A and is connected to a dashpot at B. Determine (a) The differential equation of motion for small oscillations, (b) The angle that the...
-
Owens Orchards sells apples in a large bag by weight. A sample of seven bags contained the following numbers of apples: 23, 19, 26, 17, 21, 24, 22. a. Compute the mean and median number of apples in...
-
Distinguish between operating and financial budgets.
-
Action Advertising hired Alice Jones as an account executive. She signed an employment contract under which she agreed to work for the agency for a one-year term for an annual salary of $45,000....
-
Find the average rate of change of g(x) = 4x + 4 from x = -1 to x = 1 Enter an integer or decimal number [more..]
-
Janet, Karen, and Lisa are equal general partners in JKL Partnership. In Year 1 the partnership made liquidating distributions to each of the partners. Information about the assets distributed and...
-
conditions: A continuous - time system has the following transfer function and initial 1 s+4 y(0) = 1 Find the complete response of the y(t) if the input is u(t) = e-t,t 0. H(s) = =
-
a) vividly Explains what are some of common barriers to employee's engagement with security initiatives and how can these barriers be overcome? b) Explain, what are some of the best practices are for...
-
In what type of trusted recovery process does the system recover against one or more failure types without administrator intervention while protecting itself against data loss?
-
Once a week track the price of your chosen stocks for three weeks after Feb 24 and create a simple line graph. Discuss the share price increase or decrease or trend and what you and your research...
-
Explain some common mistakes and the research findings influencing decision-making and implementing them in today's organizations. List some resources used for problem-solving in businesses. Evaluate...
-
The right type of PMO for an organization depends upon context, structure, politics, culture, leadership, PM focus, and the understanding and intention of who is involved and sponsors the PMO. Read...
-
Santo Monte forecasts that if it sells each bottle of Vodka for $20, then the demand for the product will be 15 000 bottles per year, whereas sales will be 89 per cent as high if the price is raised...
-
Represent each of the following combination of units in the correct SI form using an appropriate prefix: (a) m/ms, (b) k m, (c) k s /mg, and (d) k m N.
-
(a) Devise an alternative method for finding a basis of the corange of a matrix. (b) Use your method to find a basis for the corange of Is it the same basis as found by the method in the text? 242...
-
(a) Give an example of a non-diagonal 22 matrix for which A2 = I. (b) If A2 = I, show that det A = 1
-
Write out the details of the proof of Theorem 7.43.
-
Hambleys Toy Store is on Regent Street in London. It has a magic department near the main door. Management is considering dropping the magic department, which has consistently shown an operating...
-
Ethos Day School is a private elementary school. In addition to regular classes, after-school care is provided between 3:00 p.m. and 6:00 p.m. at SF12 per child per hour. Financial results for the...
-
The Velasquez Company, a maker of a variety of metal and plastic products, is in the midst of a business downturn and is saddled with many idle facilities. The National Hospital Supply Company has...
Study smarter with the SolutionInn App