Answered step by step
Verified Expert Solution
Question
1 Approved Answer
( write in java ) PROGRAMMING ASSIGNMENT 1 . Due Date: 0 6 . 1 1 . 2 0 2 3 / 2 3 :
write in javaPROGRAMMING ASSIGNMENT
Due Date: :
Problem
Write an object oriented program that creates the standing tables from the given all matches result separately of the Football, Basketball, Handball and Volleyball sports.
Information about the sports
In Football, in which three points are awarded to the team winning a match, with no points awarded to the losing team. If the game is drawn, each team receives one point.
In Handball, in which two points are awarded to the team winning a match, with no points awarded to the losing team. If the game is drawn, each team receives one point.
In basketball, in which two points are awarded to the team winning a match, with one point awarded to the losing team.
In volleyball, points for won and lost matches are allocated as follows:
points for the winner : or : of a match,
points for the winner : of a match,
point for the loser : of a match,
point for the loser : or : of a match
If two or more teams have same points, standings will change as follow: The team with the total number of goals scored more than the number of goals conceded will be standigns higher. If it is also equal, stand them as alphabetic order.
Restrictions
You must implement your codes by class structure.
There are teams in each sport type.
The initial scores of the teams in each sport type are zero.
The teams for each sport type are in a different group. You are expected to calculate the instant standings according to the scores in the fixtures.txt
Sample Input and Outputs
Sample input le named as xturestxt:
fixtures.txt
Sample output les
volleyball.txt
You are expected to write the output of your program to a text file named typeofsport.txt for each type of sport. for example: volleyball.txt football.txt basketball.txt handball.txt In other word, you are expected to produce output file in same directory with your source code.
The explanation of the standing table columns for each sport types are as follows:
First column denes the ranking
Second column denes the club name
Third column denes the number of played matches
Fourth column denes the number of matches won
Fifth column denes the number of times a team has nished a match with an even score or tie
Sixth column denes the number of matches loss
Seventh column denes the number of goal scored: number of goals conceded it will be number of set for volleyball
Eighth column denes the total number of points earned
How to run your program
The input file is going to be given as program argument. In order to test your program, you should follow the following steps:
Upload your java files to blackboard submission part named PA
Compile your code javac Main.java or javac java
Run your program java Main xturestxt
Control your output data and format.
Submission Notes
Do not submit any file via email. You will use blackboard submission system to submit your experiments. Other type of submissions especially by email WILL NOT BE ACCEPTED.
Save all your work until the assignment is graded.
The assignment must be original, individual work. All the duplicate or Internet works even if a citation is provided are both going to be considered as cheating.
The submission format is given below: This file hierarchy must be zipped before submission
zip
Main.java, java
Late submissions will definitely not be accepted! Problem
Write an object oriented program that creates the standing tables from the given all matches result separately
of the Football, Basketball, Hardball and Volleyball ports.
Information about the sports
In Football, in which three points are awarded to the team winning a match, with no points awarded
to the losing team. If the game is drawn, each team receives one point.
In Handball, tn which two pounts are awarded to the team winning a match, with no points awarded
to the losing team. If the game is drawn, each team receives one point.
In basketball, in which two points are awarded to the team winning a match, with one point awarded
to the losing team.
In volleyball, points for wou and lost matches are allocated as follows.
points for the winer : or : of a match.
points for the wisner of a match.
point for the loser : of a mateh
point for the loser or of a match
If two ot mote teams have same points, standings will change as follow. The team with the total
number of goals scored more than the number of goals conceded will be standigns higher. If it is
also equal, stand them as alphabetic order.
Restrictions
You must implement your codes by class structure
There are teams in each sport type.
The mitial scores of the teams in each sport rype are zero.
The teams for each sport type are in a differeat group. You are expected to calculate the
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started