you are to implement a console application for the management of a premiership table for an… 1 answer below »
In this assignment, you are to implement a console application for the management of a premiership table for an Australian Rules football league that conforms to the class diagram presented in Figure 2. The table will have the structure shown in Figure 1. Figure 1. Premiership table for the SANFL Women’s League after Round 3 In this particular league, there are 8 teams, with names of your choosing – I recommend t1-t8. Also, the table displays team names only and not team icon + team name, as in Figure 1. Position in the table is determined on the basis of premiership points (points in Figure 1); teams with the same number of premiership points are ranked according to percentage. Premiership points are awarded for each game – 2 to the winning team, 0 to the losing team and if the game is drawn, 1 to each team. As described in Assignment 1, the outcome of a game is determined using the points scored by each team, where points = goals*6+behinds. The percentage for each team is calculated as follows: percentage = score for / (score for + score against) where • score for is the total number of points scored by the team in all games played so far and • score against is the total number of points that the opposing teams have scored in all games played so far Note that in the AFL, the premiership points available per game and the way in which percentage is calculated are different, but the ranking process is the same. And what happens, if at the end of the season, two teams have the same number of premiership points, score for and score against? I don’t know.