Guys newbie here, I need your help. I need to create a program that will compute for the following entered values and will determine the equivalent grade:

Formulas:
Midterm Quizzes = 30%
Midterm CS = 20%
Midterm Exam = 50%
Final Quizzes = 40%
Final CS = 10%
Final Exam = 50%

Midterm Grade = sum of MIDTERM PERIOD
(quiz average * 30%)+(cs * 20%)+(exam * 50%)
Final Grade = sum of FINAL PERIOD
(quiz average * 40%)+(cs * 10%)+(exam * 50%)

Equivalent:

95-100="4.0"

91-94="3.5"

87-90="3.0"

83-86="2.5"

79-82="2.0"

75-78="1.5"

70-74="1.0"

<70="R"

I'm still a newbie and I'm trying to learn... Your help is very much appreciated. Thanks!

4
Contributors
9
Replies
10
Views
8 Years
Discussion Span
Last Post by emcee123

I'm still a newbie and I'm trying to learn...

Forum rule is We only give homework help to those who show effort.
What is the best way to learn? By practicing and making mistakes from which you hopefully learn and avoid them next time. So if you please get to work, show us what you did and tell is where is problem.

Edited by peter_budo: n/a

I really have no idea on how to do that. Like what I've said, I'm still a newbie. They assigned me to do that work for it to serve as a reference for my other works. I got a lot of things to do now but they said that is the easiest one. I just need an idea, how to start, etc.. Help please..

You must have some background otherwise this wouldn't be assigned to you. And everyone has lots of things to do beside helping somebody who is not willing to cooperate and just looking forward to cheat his way through...

I've started it for you and I think you can work on from here...if this is what you're intending to do:

``````System.out.println("Enter your first quiz grade: ");
Scanner sc = new Scanner(System.in);
int firstQ = sc.nextInt();
int secondQ = sc.nextInt();
int thirdQ = sc.nextInt();
double MidQuizAvg = (firstQ + secondQ + thirdQ)/3;
double MidtermCS = sc.nextInt();
double MidtermExam = sc.nextInt();

double MidtermGrade = (MidQuizAvg * .3 + MidtermCS * .2 + MidtermExam * .5);

There is error checking to consider and also the 2nd part to do ...so if this is what you're looking for then try to work from this :)

Thanks for the reply, that really helps. I'll try to work it out now, and I'll be posting here for updates.

Guys I have a problem. I'm about to finish but there's an error. Why is it that the "Scanner sc = new Scanner(System.in);" part has an underline. It says, "Scanner cannot be resolved to a type"

What installation of java you are using? and what operating system?

did you import the scanner?
``import java.util.Scanner;``