Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

( write in java ) PROGRAMMING ASSIGNMENT 1 . Due Date: 0 6 . 1 1 . 2 0 2 3 / 2 3 :

(write in java)PROGRAMMING ASSIGNMENT 1.
Due Date: 06.11.2023/23:59
1 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.
1.1 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:
3 points for the winner 3:0 or 3:1 of a match,
2 points for the winner 3:2 of a match,
1 point for the loser 2:3 of a match,
0 point for the loser 0:3 or 1:3 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.
1.2 Restrictions
You must implement your codes by class structure.
There are 4 teams in each sport type.
The initial scores of the 4 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
1.2 Sample Input and Outputs
Sample input le named as xtures.txt:
fixtures.txt
Sample output les
volleyball.txt
You are expected to write the output of your program to a text file named type_of_sport.txt for each type of sport. (for example: volleyball.txt, football.txt, basketball.txt, handball.txt). In other word, you are expected to produce 4 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
1.4 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 PA1
Compile your code (javac Main.java or javac *.java)
Run your program (java Main xtures.txt)
Control your output data and format.
2 Submission Notes
Do not submit any file via e-mail. You will use blackboard submission system to submit your experiments. Other type of submissions especially by e-mail 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!1 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 5ports.
1.1 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.
3 points for the winer 3:0 or 3:1 of a match.
2 points for the wisner 3.2 of a match.
1 point for the loser 2:3 of a mateh
0 point for the loser 0.3 or 1.3 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.
1.2 Restrictions
You must implement your codes by class structure
There are 4 teams in each sport type.
The mitial scores of the 4 teams in each sport rype are zero.
The teams for each sport type are in a differeat group. You are expected to calculate the
image text in transcribed

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Pro SQL Server Wait Statistics

Authors: Enrico Van De Laar

1st Edition

1484211391, 9781484211397

More Books

Students also viewed these Databases questions