Write a Python program which computes win/loss record, average score and average point spread of a sports team (or player) Your program must: Pick your favorite team or individual sport which has a single opponent. You will be prompting the user for the points scored by your team and their opponent for a set of games/matches - for sports with only a few games per season (like American football) the set would be the entire season. However, for a sport like baseball with 60 games per season, you may choose to use a smaller set for testing - say the 7 games for the world series. Prompt the user for the name of the team/player and use it to aid in future prompts Prompt the user for the number of games/matches played FOR EACH GAME PLAYED, prompt the user for the points of the favorite team/player and of the opposing team/player Your program must then print the following: win/loss record (how many games your team/player won and how many that team lost) the total points your favorite team/player earned the average points per game your favorite team/player earned the average "point spread" of the games (Point spread is the difference of the points scored in a game).

C++ Programming: From Problem Analysis to Program Design
8th Edition
ISBN:9781337102087
Author:D. S. Malik
Publisher:D. S. Malik
Chapter5: Control Structures Ii (repetition)
Section: Chapter Questions
Problem 20PE: When you borrow money to buy a house, a car, or for some other purpose, you repay the loan by making...
icon
Related questions
Question

Write a Python program which computes win/loss record, average score and average point spread of a sports team (or player)

Your program must:

Pick your favorite team or individual sport which has a single opponent. You will be prompting the user for the points scored by your team and their opponent for a set of games/matches - for sports with only a few games per season (like American football) the set would be the entire season. However, for a sport like baseball with 60 games per season, you may choose to use a smaller set for testing - say the 7 games for the world series.

  • Prompt the user for the name of the team/player and use it to aid in future prompts
  • Prompt the user for the number of games/matches played
  • FOR EACH GAME PLAYED, prompt the user for the points of the favorite team/player and of the opposing team/player
  • Your program must then print the following:
    • win/loss record (how many games your team/player won and how many that team lost)
    • the total points your favorite team/player earned
    • the average points per game your favorite team/player earned
    • the average "point spread" of the games (Point spread is the difference of the points scored in a game). 

Can I get an example code please in python 

Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 3 steps with 1 images

Blurred answer
Knowledge Booster
Random Class and its operations
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
C++ Programming: From Problem Analysis to Program…
C++ Programming: From Problem Analysis to Program…
Computer Science
ISBN:
9781337102087
Author:
D. S. Malik
Publisher:
Cengage Learning
C++ for Engineers and Scientists
C++ for Engineers and Scientists
Computer Science
ISBN:
9781133187844
Author:
Bronson, Gary J.
Publisher:
Course Technology Ptr