Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Can someone help fill in the blanks in java please? Thanks /** * This class deterimes a passing or failing grade for an exam *

Can someone help fill in the blanks in java please? Thanks

/**

* This class deterimes a passing or failing grade for an exam

* This class is a subclass of PassFailActivity

*

* @author ()

* @version ()

*/ (

1) ____________________________________________________________________

{

private int numQuestions; // number of questions

private double pointsEach; //points for each question

private int numMissed; //number of questions missed

/**

* The constructor sets the number of questions, the number of questions missed, and the minimum

* passing score.

* @param questions The number of questions

* @param missed The number of questions missed

* @param minPassing The minimum passing score

*/

(2) public PassFailExam(_______________________________________________________)

{

//Call the superclass constructor

(3) _____________________________________; //declare a local variable for the score

(4) _______________________________________; //Set the numQuestions and numMissed fields

(5) _______________________________________; numMissed = missed;

//Calculate the points for each question and the numeric score for this exam

pointsEach = 100.0 / questions;

numericScore = 100.0 - (missed * pointsEach);

//call the superclass's setscore method to set the numeric score

(6) ____________________________________________;

}

/**

* The getPointsEach method returns the number of points each question is worth

*/

public double getPointsEach()

{

return pointsEach;

}

/**

* The getNumMissed method returns the number of questions missed

*/

public int getNumMissed() { return numMissed;

}

}

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_2

Step: 3

blur-text-image_3

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

Essential SQLAlchemy Mapping Python To Databases

Authors: Myers, Jason Myers

2nd Edition

1491916567, 9781491916568

More Books

Students also viewed these Databases questions

Question

What is the purpose of the Salary Structure Table?

Answered: 1 week ago

Question

What is the scope and use of a Job Family Table?

Answered: 1 week ago