Ask Question, Ask an Expert

+61-413 786 465

info@mywordsolution.com

Ask Java Expert


Home >> Java

After hearing the excellent job you have done designing software solutions for entities in and around campus, your work comes full circle when the University of Florida English department asks you to create an autograder for its introductory class. There are many types of students who are taking this class. Some are high-achieving high school students, some UF undergraduate students, and some graduate students who need a refresher. They would like to create a parent object that can be extended to provide functionality for a number of kinds of students. The department would also like to have the ability to supply the name of a file containing an essay (as a numeric ID) and have you grade the essay, by deducting an appropriate number of points for every word that is misspelled. After reading in the UF ID, which you will use to open the correct essay file, you will create an output file that contains the student's grade.

Objective

Read in the file given

Count the number of misspelled words

Deduct points accordingly for each misspelled word.

-1 High School Student, -3 College Student, -5 Graduate Student

Generate an output file that contains the student's graded output

Your Assignment

You will need to create five files complete this project and name them exactly as follows: Project5.java, Student.java, HighSchoolStudent.java,UndergraduateStudent.java, and GraduateStudent.java. TheProject5.java file will be the only file to contain a main() method. Each of the .java files and their associated classes are described below:

The Student Class

The Student class, which is stored in Student.java, will act as your parent class from which the different types of students will be derived from. This class must have the following members:

Fields for the following attributes

Name
ID Number

"Getter"/"Setter" methods for each attribute

public String getName()
public void setName(String n)
public String getIDNumber()
public void setIDNumber(int id)

A method that will return a String of all of the attributes for this object

public String toString()

An appropriate constructor

The constructor must initialize both fields of the Student object with the constructor's parameters public Student(String n, int id) The HighSchoolStudent ClassThe HighSchoolStudent class, which is stored in HighSchoolStudent.java, will be a child class of the Student Class.

This class must have the following members:

A field for the following attribute

Name Of School

A "getter" and "setter" method for this attribute

public String getNameOfSchool()
public void setNameOfSchool(String schoolName)

A method that will return a String of all of the attributes for this object

public String toString()

An appropriate constructor

The constructor must initialize both fields of the Student object with the constructor's parameters public HighSchoolStudent(String n, int id, String schoolName) The UndergraduateStudent ClassThe UndergraduateStudent Class, which is stored inUndergraduateStudent.java, will also be a child class of the Student Class. This class must have the following members:

A field for the following attribute

Major

A "getter" and "setter" method for this attribute

public String getMajor()
public void setMajor(String major)

A method that will return a String of all of the attributes for this object

public String toString()

An appropriate constructor

The constructor must initialize both fields of the Student object with the constructor's parameters public UndergraduateStudent(String n, int id, String major) The GraduateStudent ClassThe GraduateStudent Class, which is stored in GraduateStudent.java, will be the final child class of the Student Class. This classmust have the following members:

Fields for the following attributes

Major

Advisor

"Getter"/"Setter" methods for each attribute

public String getMajor()
public void setMajor(String major)
public String getAdvisor()
public void setAdvisor(String advisor)

A method that will return a String of all of the attributes for this object

public String toString()

An appropriate constructor

The constructor must initialize both fields of the Student object with the constructor's parameters public GraduateStudent(String n, int id, String major, String advisor)The Project5 ClassThe Project5 Class, which is stored in Project5.java, will hold the main method of your program. Your main method will first read in the words that make up your dictionary from a file, and will then create different Student objects based on the files that your program will read from. Your program will then grade the essay that the student has written. Your program should handle FileNotFoundException and print to the console as shown in the sample below!

Your main method will prompt the user to specify the file that hold the dictionary information. You will then attempt to open the file and input the contents of the file into an array to be used by the remainder of your program.

Your program will then ask the user to specify the name of the file that holds the student information. You will then attempt to open the file, create a Student object based on the information given in the file and read the student's essay from the file.

The first line in the file will identify the classification of the student (High School, Undergraduate, or Graduate)

The following lines will supply the values for the attributes of the specific classification, such as Name, ID Number, and Name Of School for a High School Student.

The remainder of the file will be the essay that the student has written.

After everything is read from the student file, your program will grade the essay and output the result to a new file.

You will read though the essay and determine whether or not a word is misspelled. If a word is misspelled, deduct the appropriate number of points from the student's grade. The grade cannot be negative!

Java, Programming

  • Category:- Java
  • Reference No.:- M91616226

Have any Question?


Related Questions in Java

In relation to javaa what is constructor the purpose of

(In relation to Java) A. What is constructor? the purpose of default constructor? B. How do you get a copy of the object but not the reference of the object? C. What are static variables and instance variables? D. Compar ...

Question slideshows or carousels are very popular in

Question : Slideshows (or carousels) are very popular in websites. They allow web developers to display news or images on the website in limited space. In this code challenge, you are required to complete the JavaScript ...

Overviewyou are required to use java se 80 and javafx to

Overview You are required to use Java SE 8.0 and JavaFX to develop a Graphical User Interface (GUI) for the FlexiRent rental property management program created in Assignment 1. This assignment is designed to help you: 1 ...

Assignment - java program using array of objectsobjectives

Assignment - JAVA Program using array of objects Objectives - This assessment item relates to the course learning outcomes as stated in the Unit Profile. Details - For this assignment, you are required to develop a Menu ...

Overviewyou are required to use java se 80 and javafx to

Overview You are required to use Java SE 8.0 and JavaFX to develop a Graphical User Interface (GUI) for the FlexiRent rental property management program created in Assignment 1. This assignment is designed to help you: 1 ...

Project descriptionwrite a java program to traverse a

Project Description: Write a java program to traverse a directory structure (DirWalker.java) of csv files that contain csv files with customer info. A simple sample in provided in with the sample code but you MUST will r ...

Solving 2nd degree equationsbull write the following java

Solving 2nd degree equations • Write the following Java methods • boolean real-sols(double a, double b, double c): it returns true if the 2nd degree equation ax2 + bx + c has real solutions • double solution1(double a, d ...

Operating systems assignment -problem 1 sharing the bridgea

Operating Systems Assignment - Problem 1: Sharing the Bridge A new single lane bridge is constructed to connect the North Island of New Zealand to the South Island of New Zealand. Farmers from each island use the bridge ...

Can someone please help me with the following java

can someone please help me with the following java question The input is an N by N matrix of nonnegative integers. Each individual row is a decreasing sequence from left to right. Each individual column is a decreasing s ...

Answer the following question whats the difference public

Answer the following Question : What's the difference public inheritance and private inheritance? What can derived classes inherit from base classes? What cannot be inherited from base classes?

  • 4,153,160 Questions Asked
  • 13,132 Experts
  • 2,558,936 Questions Answered

Ask Experts for help!!

Looking for Assignment Help?

Start excelling in your Courses, Get help with Assignment

Write us your full requirement for evaluation and you will receive response within 20 minutes turnaround time.

Ask Now Help with Problems, Get a Best Answer

Why might a bank avoid the use of interest rate swaps even

Why might a bank avoid the use of interest rate swaps, even when the institution is exposed to significant interest rate

Describe the difference between zero coupon bonds and

Describe the difference between zero coupon bonds and coupon bonds. Under what conditions will a coupon bond sell at a p

Compute the present value of an annuity of 880 per year

Compute the present value of an annuity of $ 880 per year for 16 years, given a discount rate of 6 percent per annum. As

Compute the present value of an 1150 payment made in ten

Compute the present value of an $1,150 payment made in ten years when the discount rate is 12 percent. (Do not round int

Compute the present value of an annuity of 699 per year

Compute the present value of an annuity of $ 699 per year for 19 years, given a discount rate of 6 percent per annum. As