Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Submit a link to your program on Google Classroom.A college is offering courses and needs a program designed to calculate tuition.Requirements: The program will consist

Submit a link to your program on Google Classroom.A college is offering courses and needs a program designed to calculate tuition.Requirements: The program will consist of 4 class. Each non-driver class should utilize Javadoc comments (see the codeHS lesson if necessary).Course Class this class records the details of a course. Instance variables (fields)o Name of the course (i.e. IT 168)o Credit hours as an integero Days of the week class meets as a stringo Time of the day the class meets as a stringo Boolean variable indicating whether the course has a lab Methodso Constructor (parameterized to accept all five instance variables)o Getters and setters for all five instance variableso toString method that should return the contents of the course in a readable format (seesample output for an example)InStateRegistration Class This class calculations the tuition cost for in-state students. In-state studentscan take 12-18 credit hours for the same cost. If they enroll in less than 12 hours, they will be subject tothe hourly rate. Each student that registers must also pay a one-time technology fee, which is addedto the final total. Constant variableso Full time tuition rate =3289o Minimum full time hours =12o Maximum full time hours =18o Per hour rate =305.5o Lab fees =35.0o Technology fee =250.0 Instance variableso Current semester hourso Number of labso Public static variable for count that keeps track of the total in-state students created(see codeHS lesson if necessary) Methodso Constructor that accepts the hours and number of labs as parameters. Since nostudent is allowed to register for more than 18 credit hours, if the total semester hours isnot greater than 18, then it sets the values of hours and labs and adds one to the countfor each InStateRegistration created. It generates an error message if the total hours is more than 18. Values are set to0 and the count is NOT incremented.o Getters and setters for hours and labso toString method that should return the contents of this class in a readable format (seethe sample output for an example)o calculateTuition This method returns the result of calculating the tuition based on thetotal number of hours and the number of labs. If the total number of hours is less than12, then the per credit rate is used multiplied by total number of hours. If hours arebetween 12 and 18, then full time tuition rate is used. After calculating the tuition, youmust also add the lab fee cost, which is number of labs multiplied by lab fees.total tuition = fulltime rate + number of labs * lab feesortotal tuition = per hour rate * current semester hours + number of labs * lab feeso calculateTotalCost this method returns the result of adding the technology fee to thetotal tuition that calls the calculateTuition method.OutOfStateRegistration Class This class calculates the tuition cost for out-of-state students. Studentsout-of-state are charged a per credit hour rate, regardless of hours. Each student that registers mustalso pay a one-time technology fee which is added to the final total. Constant variableso Per hours rate =355.5o Lab fees =65.0o Technology fee =350.0 Instance variableso Current semester hourso Number of labso Public state variable for count that keeps track of the total out-of-state studentscreated (see codeHS lesson for example) Methodso Constructor that accepts the hours and number of labs as parameters. If total semesterhours is not greater than 18, then it sets the values of hours and labs and adds one tothe count for each OutStateRegistration created. It generates an error message if the total hours is more than 18. Values are set to0 and count is NOT incremented.o Getters and setters for hours and labso toString method that will return the formatted contents of the out-of-state students. Seesample output for format. Note that Number of labs should not be output if the numberof labs is 0.o calculateTuition This method returns the result of calculating the tuition based on thetotal number of hours and the number of labso total tuition = per hour rate * current semester hours + number of labs * lab feeso calculateTotalCost This method returns the result of adding the technology fee to thetotal tuition that calls the calculateTuition method.Registration Class (Driver) This class will contain your main method and manage the construction ofthe courses as well as registration of the students. Instantiate six Course objects with the information below. You will hard-code these values in,calling the constructor of the course class and passing in the values from the table.CoursenameCredithoursDays Time Labs?Math 1013 TR 1:00-2:15 FalseEngl 1054 MW 3-4:15 FalseIT 1684 MW 9-10:15 TrueIT 2543 TR 10:30-11:45FalseChem 1014 MW 11-12:15 TrueIT 2103 TR 3-4:15 False Until the user indicates they are done adding student registrations, you should display themenu of the courses offered and allow the user to select a course to add. You will keep track of the total credit hours and the number of lab courses for thestudent and then once all courses have been selected, a menu will be output thatallows the user to select whether the student is in state or out of state, and theappropriate object is created and costs are output. Once all information for a student is processed, the user should be prompted as towhether or not there is another student to register. If yes, repeat for the next student.Once all students have been processed, output a total for all students, which shouldinclude total number of each type of student and total tuition collected. Methodso displayCourseMenu this method accepts all six courses created and uses the namesof these courses to display a menu (see sample output for an example).o determineType this method displays a menu for the two types of students (in-state and Out-of-state)

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

Database Systems For Advanced Applications 17th International Conference Dasfaa 2012 Busan South Korea April 2012 Proceedings Part 1 Lncs 7238

Authors: Sang-goo Lee ,Zhiyong Peng ,Xiaofang Zhou ,Yang-Sae Moon ,Rainer Unland ,Jaesoo Yoo

2012 Edition

364229037X, 978-3642290374

More Books

Students also viewed these Databases questions