Create a fee invoice application for students attending Valence College, a college in the State of Florida. There are two types of students: graduate and undergraduate. Out-of-state undergraduate students pay twice the tuition of Florida-resident undergraduate students (all students pay the same health and id fees). A graduate student is either a PhD or a MS student. PhD students don't take any courses, but each has an advisor and a research subject. Each Ms and Phd student must be a teaching assistant for one undergraduate course. MS students can only take graduate courses. A course with a Course Number (crn) less than 5000 is considered an undergraduate course, and courses with a 5000 crn or higher are graduate courses. CRN Course Credit Hours. 4587 MAT 236 4 4599 COP 220 3 8997 GOL 124 1 9696 COP 100 3 4580 MAT 136 1 2599 COP 260 3 1997 CAP 424 1 5696 KOL 110 2 7587 MAT 936 5 2599 COP 111 3 6997 GOL 109 1 2696 COP 101 3 5580 MAT 636 2 2099 COP 268 3 4997 CAP 427 1 3696 KOL 910 2 Example of an MS student Name Emily Jones Id em1254 Courses taken 7587 and 8997 TA for 1997 Example of an PhD student: Name Zaydoun BenSellam Id zb5954 Advisor Gary Richarson Research Subject Fuzzy Topology TA for 2599 It costs, for undergraduate Florida residents, $120.25 per credit hour, and all MS students pay $300 per credit hour. in addition to $35.00 charged for health and id services. Undergraduate Students with gpa of 3.5 or higher receive a discount of 25% when the total payments exceed $500. PhD students pay a separate research fee of $700. A fee invoice for an undergraduate student should look like VALENCE COLLEGE ORLANDO FL 10101 Fee Invoice Prepared for Student: KJ2959-KARIM JONES (Karim, a FL resident, has gpa higher than 3.5 gpa). 1 Credit Hour = $120.25 CRN CR_PREFIX CR_HOURS 4599 COP 220 3 $ 360.75 4587 MAT 236 4 $ 481.00 $35.00 Health & id fees $ 876.75 -$219.18 TOTAL PAYMENTS $ 657.56 A fee invoice for an MS student should look like. VALENCE COLLEGE ORLANDO FL 10101 Fee Invoice Prepared for Student: KA2959-ERICKA JUNAID 1 Credit Hour = $300.00 CRN CR PREFIX CR HOURS 6997 GOL 109 1 $ 300.00 Health & id fees $35.00 tal Payments $335.00 A fee invoice for an PhD student should look like VALENCE COLLEGE ORLANDO FL 10101 Fee Invoice Prepared for Student: J02978-John JUNAID John's research subject: Climate Change RESEARCH Climate Change $ 700.00 Health & id fees $ 35.00 Total Payments $ 735.00 1) In addition to the DriverClass class, you will need to add all the classes shown on the inheritance hierarchy shown above. (Student, Graduate Student, Undergraduate Student, Ms Student and PhdStudent). Both Student and Graduate Student are to be made abstract. The Student class must contain the abstract method: abstract public void printInvoice (); 2) The abstract method, printInvoice, is to be overridden to display the right fee invoice, depending on the type of the student. Data fields of all classes are to be made private. 3) Do not change anything in the DriverClass.java (see skeleton below). You may add your own methods or data whenever you see that becomes necessary. Just don't duplicate code! 4) Your job is to add the necessary code. public class DriverClass { // DO NOT CHANGE ANYTHING IN THIS CLASS (DriverClass) public static void main(String[] args) { Student s; S = new PhdStudent ("Zaydoun BenSellam", "zb5954", "Ga "Gary Richarson", "Fuzzy Topology", 2599 ); s.printInvoice (); int[] gradCrns Taken = {7587,8997) ; S = new MsStudent ( "Emily Jones", "em1254", gradCrns Taken, 1997); s.printInvoice (); int[] undergradCrns Taken = {4587,2599); s new Undergraduate Student ("Jamila Jones". "ja5225", ja radCrns Taken, 3.0, false); s.printInvoice (); }//end of main } abstract class Student ( public Student String name } abstract public void printInvoice (); } class Undergraduate Student extends Student { public Undergraduate Student (String name, String id, int [] undergradCrns Taken, double gpa, boolean resident) { super (name, id); } String name, String id) { @Override public void printInvoice () { } } abstract class Graduate Student extends Student { public Graduate Student (String name, String id, int crn) { //crn is the crn that the grad student is a teaching assistant for super name, id); } } class PhdStudent extends Graduate Student { // ・・・ public PhdStudent (String name, String id, String advisor, String research Subject, int crn) { //crn is the course number that the Phd student is a teaching assistant for super name, id, crn ); } @Override public void printInvoice () { } } class Ms Student extends Graduate Student { public MsStudent (String name, String id, int [] gradCrns Taken, int crn) { // gradCourses Taken is the array of the crns that the Ms student is taking //crn is the course number that the Phd student is a teaching assistant for super name, id, crn); } @Override public void printInvoice () { }

EBK JAVA PROGRAMMING
9th Edition
ISBN:9781337671385
Author:FARRELL
Publisher:FARRELL
Chapter14: Introduction To Swing Components
Section: Chapter Questions
Problem 10PE
icon
Related questions
Question
Create a fee invoice application for students attending Valence College, a college in the State of Florida. There are two types of students: graduate and
undergraduate. Out-of-state undergraduate students pay twice the tuition of Florida-resident
undergraduate students (all students pay the same health and id fees). A graduate student is either a PhD or a MS student. PhD students don't take any
courses, but each has an advisor and a research subject. Each Ms and Phd student must be a teaching assistant for one undergraduate course. MS students can
only take graduate courses. A course with a Course Number (crn) less than 5000 is considered an undergraduate course, and courses with a 5000 crn or higher
are graduate courses.
CRN Course Credit Hours.
4587 MAT 236 4
4599 COP 220 3
8997 GOL 124 1
9696 COP 100 3
4580 MAT 136 1
2599 COP 260 3
1997 CAP 424 1
5696 KOL 110 2
7587 MAT 936 5
2599 COP 111 3
6997 GOL 109 1
2696 COP 101 3
5580 MAT 636 2
2099 COP 268 3
4997 CAP 427 1
3696 KOL 910 2
Example of an MS student
Name Emily Jones
Id em1254
Courses taken 7587 and 8997
TA for 1997
Example of an PhD student:
Name Zaydoun BenSellam
Id zb5954
Advisor Gary Richarson
Research Subject Fuzzy Topology
TA for 2599
It costs, for undergraduate Florida residents, $120.25 per credit hour, and all MS students pay $300 per credit hour. in addition to $35.00 charged for
health and id services. Undergraduate Students with gpa of 3.5 or higher receive a discount of 25% when the total payments exceed $500. PhD students pay a
separate research fee of $700.
A fee invoice for an undergraduate student should look like
VALENCE COLLEGE
ORLANDO FL 10101
Fee Invoice Prepared for Student:
KJ2959-KARIM JONES (Karim, a FL resident, has gpa higher than 3.5 gpa).
1 Credit Hour = $120.25
CRN CR_PREFIX CR_HOURS
4599 COP 220 3 $ 360.75
4587 MAT 236 4 $ 481.00
$35.00
Health & id fees
$ 876.75
-$219.18
TOTAL PAYMENTS $ 657.56
A fee invoice for an MS student should look like.
VALENCE COLLEGE
ORLANDO FL 10101
Fee Invoice Prepared for Student:
KA2959-ERICKA JUNAID
1 Credit Hour = $300.00
CRN CR PREFIX CR HOURS
6997 GOL 109 1 $ 300.00
Health & id fees $35.00
tal Payments $335.00
A fee invoice for an PhD student should look like
VALENCE COLLEGE
ORLANDO FL 10101
Fee Invoice Prepared for Student:
J02978-John JUNAID John's research subject:
Climate Change
RESEARCH
Climate Change $ 700.00
Health & id fees $ 35.00
Total Payments $ 735.00
1) In addition to the DriverClass class, you will need to add all the classes shown on the inheritance hierarchy shown above. (Student, Graduate Student,
Undergraduate Student, Ms Student and PhdStudent). Both Student and Graduate Student are to be made abstract. The Student class must contain the abstract
method:
abstract public void printInvoice ();
2) The abstract method, printInvoice, is to be overridden to display the right fee invoice, depending on the type of the student. Data fields of all classes
are to be made private.
3) Do not change anything in the DriverClass.java (see skeleton
below). You may add your own methods or data whenever you see that becomes necessary. Just don't duplicate code!
4) Your job is to add the necessary code.
public class DriverClass {
Transcribed Image Text:Create a fee invoice application for students attending Valence College, a college in the State of Florida. There are two types of students: graduate and undergraduate. Out-of-state undergraduate students pay twice the tuition of Florida-resident undergraduate students (all students pay the same health and id fees). A graduate student is either a PhD or a MS student. PhD students don't take any courses, but each has an advisor and a research subject. Each Ms and Phd student must be a teaching assistant for one undergraduate course. MS students can only take graduate courses. A course with a Course Number (crn) less than 5000 is considered an undergraduate course, and courses with a 5000 crn or higher are graduate courses. CRN Course Credit Hours. 4587 MAT 236 4 4599 COP 220 3 8997 GOL 124 1 9696 COP 100 3 4580 MAT 136 1 2599 COP 260 3 1997 CAP 424 1 5696 KOL 110 2 7587 MAT 936 5 2599 COP 111 3 6997 GOL 109 1 2696 COP 101 3 5580 MAT 636 2 2099 COP 268 3 4997 CAP 427 1 3696 KOL 910 2 Example of an MS student Name Emily Jones Id em1254 Courses taken 7587 and 8997 TA for 1997 Example of an PhD student: Name Zaydoun BenSellam Id zb5954 Advisor Gary Richarson Research Subject Fuzzy Topology TA for 2599 It costs, for undergraduate Florida residents, $120.25 per credit hour, and all MS students pay $300 per credit hour. in addition to $35.00 charged for health and id services. Undergraduate Students with gpa of 3.5 or higher receive a discount of 25% when the total payments exceed $500. PhD students pay a separate research fee of $700. A fee invoice for an undergraduate student should look like VALENCE COLLEGE ORLANDO FL 10101 Fee Invoice Prepared for Student: KJ2959-KARIM JONES (Karim, a FL resident, has gpa higher than 3.5 gpa). 1 Credit Hour = $120.25 CRN CR_PREFIX CR_HOURS 4599 COP 220 3 $ 360.75 4587 MAT 236 4 $ 481.00 $35.00 Health & id fees $ 876.75 -$219.18 TOTAL PAYMENTS $ 657.56 A fee invoice for an MS student should look like. VALENCE COLLEGE ORLANDO FL 10101 Fee Invoice Prepared for Student: KA2959-ERICKA JUNAID 1 Credit Hour = $300.00 CRN CR PREFIX CR HOURS 6997 GOL 109 1 $ 300.00 Health & id fees $35.00 tal Payments $335.00 A fee invoice for an PhD student should look like VALENCE COLLEGE ORLANDO FL 10101 Fee Invoice Prepared for Student: J02978-John JUNAID John's research subject: Climate Change RESEARCH Climate Change $ 700.00 Health & id fees $ 35.00 Total Payments $ 735.00 1) In addition to the DriverClass class, you will need to add all the classes shown on the inheritance hierarchy shown above. (Student, Graduate Student, Undergraduate Student, Ms Student and PhdStudent). Both Student and Graduate Student are to be made abstract. The Student class must contain the abstract method: abstract public void printInvoice (); 2) The abstract method, printInvoice, is to be overridden to display the right fee invoice, depending on the type of the student. Data fields of all classes are to be made private. 3) Do not change anything in the DriverClass.java (see skeleton below). You may add your own methods or data whenever you see that becomes necessary. Just don't duplicate code! 4) Your job is to add the necessary code. public class DriverClass {
// DO NOT CHANGE ANYTHING IN THIS CLASS (DriverClass)
public static void main(String[] args) {
Student s;
S = new PhdStudent ("Zaydoun BenSellam",
"zb5954",
"Ga
"Gary Richarson",
"Fuzzy Topology",
2599 );
s.printInvoice ();
int[] gradCrns Taken = {7587,8997) ;
S = new MsStudent ( "Emily Jones",
"em1254",
gradCrns Taken,
1997);
s.printInvoice ();
int[] undergradCrns Taken = {4587,2599);
s new Undergraduate Student ("Jamila Jones".
"ja5225",
ja radCrns Taken,
3.0,
false);
s.printInvoice ();
}//end of main
}
abstract class Student (
public Student String name
}
abstract public void printInvoice ();
}
class Undergraduate Student extends Student {
public Undergraduate Student (String name, String id, int [] undergradCrns Taken, double gpa, boolean resident)
{
super (name, id);
}
String name, String id) {
@Override
public void printInvoice () {
}
}
abstract class Graduate Student extends Student {
public Graduate Student (String name, String id, int crn) {
//crn is the crn that the grad student is a teaching assistant for
super name, id);
}
}
class PhdStudent extends Graduate Student {
// ・・・
public PhdStudent (String name, String id, String advisor, String research Subject, int crn) {
//crn is the course number that the Phd student is a teaching assistant for
super name, id, crn );
}
@Override
public void printInvoice () {
}
}
class Ms Student extends Graduate Student {
public MsStudent (String name, String id, int [] gradCrns Taken, int crn) {
// gradCourses Taken is the array of the crns that the Ms student is taking
//crn is the course number that the Phd student is a teaching assistant for
super name, id, crn);
}
@Override
public void printInvoice () {
}
Transcribed Image Text:// DO NOT CHANGE ANYTHING IN THIS CLASS (DriverClass) public static void main(String[] args) { Student s; S = new PhdStudent ("Zaydoun BenSellam", "zb5954", "Ga "Gary Richarson", "Fuzzy Topology", 2599 ); s.printInvoice (); int[] gradCrns Taken = {7587,8997) ; S = new MsStudent ( "Emily Jones", "em1254", gradCrns Taken, 1997); s.printInvoice (); int[] undergradCrns Taken = {4587,2599); s new Undergraduate Student ("Jamila Jones". "ja5225", ja radCrns Taken, 3.0, false); s.printInvoice (); }//end of main } abstract class Student ( public Student String name } abstract public void printInvoice (); } class Undergraduate Student extends Student { public Undergraduate Student (String name, String id, int [] undergradCrns Taken, double gpa, boolean resident) { super (name, id); } String name, String id) { @Override public void printInvoice () { } } abstract class Graduate Student extends Student { public Graduate Student (String name, String id, int crn) { //crn is the crn that the grad student is a teaching assistant for super name, id); } } class PhdStudent extends Graduate Student { // ・・・ public PhdStudent (String name, String id, String advisor, String research Subject, int crn) { //crn is the course number that the Phd student is a teaching assistant for super name, id, crn ); } @Override public void printInvoice () { } } class Ms Student extends Graduate Student { public MsStudent (String name, String id, int [] gradCrns Taken, int crn) { // gradCourses Taken is the array of the crns that the Ms student is taking //crn is the course number that the Phd student is a teaching assistant for super name, id, crn); } @Override public void printInvoice () { }
AI-Generated Solution
AI-generated content may present inaccurate or offensive content that does not represent bartleby’s views.
steps

Unlock instant AI solutions

Tap the button
to generate a solution

Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
EBK JAVA PROGRAMMING
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT
Np Ms Office 365/Excel 2016 I Ntermed
Np Ms Office 365/Excel 2016 I Ntermed
Computer Science
ISBN:
9781337508841
Author:
Carey
Publisher:
Cengage
A Guide to SQL
A Guide to SQL
Computer Science
ISBN:
9781111527273
Author:
Philip J. Pratt
Publisher:
Course Technology Ptr
Oracle 12c: SQL
Oracle 12c: SQL
Computer Science
ISBN:
9781305251038
Author:
Joan Casteel
Publisher:
Cengage Learning
Microsoft Visual C#
Microsoft Visual C#
Computer Science
ISBN:
9781337102100
Author:
Joyce, Farrell.
Publisher:
Cengage Learning,