Please help trying to simplify my java code thanks.?

I’m trying to puzzle out a way for just one method being recognized by simply another.I’d like the 1st applicant way to recognize the satscore in addition to actscore.if i enter the 1 i’d like to see to be able to execute the satScore portion etc ..I don’t realize how to get this software to punctual the LAY questions every time a number ONE is inserted and BEHAVE questions if a number 2 is entered.Do Need to create a brand new method to acquire these two techniques to work together

i’d like to transform the code so the execution appears like this:
The program compares a couple of applicants to
determine what design seems like the stronger
client.For each and every candidate I’ll need
either SEATED or WORK scores plus a weighted GPA.

Tips for consumer #1:
are you experiencing 1) LAY scores or perhaps 2) WORK scores 1
SEATED math 450
SEATED critical reading through 530
SEATED writing 490
quiz score = 60.0
overall GPA SEVERAL.4
greatest extent GPA 4.0
Transcript Multiplier 0.9
GPA rating = 76.5

tips for consumer #2:
are you experiencing 1) LAY scores or perhaps 2) WORK scores 2
REACT English 25
REACT math 20
REACT reading 18
REACT science 15
quiz score = 54.44
overall GPA SEVERAL.3
greatest extent GPA 4.0
Transcript Multiplier 0.95
GPA rating = 78.38

Initial applicant total score = 136.5
Second applicant total score = 132.82
The initial applicant seems to be better

this eq with regard to gpa will be:
(actual_gpa/max_gpa)*100*transcript_mu

signific java.util.*;
public class Own up
public static useless main(String args)

Protection console = different Scanner(System.in);
introduction();
int applicant1 = firstApplicant (console);
int applicant2 = secondApplicant(console);
double scoreOne = satScore(console);
double scoreTwo = actScore(console);
scoreComparison (scoreOne, scoreTwo);

public static useless introduction()

Method.out.println(“This course compares a couple of applicants to”);
Method.out.println(“determine what design seems like the stronger”);
Method.out.println(“applicant.Per candidate I’ll need”);
Method.out.println(“either LAY or REACT scores plus a weighted GPA.”);
Method.out.println();

public static int firstApplicant (Scanner console)

Method.out.println(“Information for your first consumer:”);
Method.out.print(“do you have 1) LAY sores and also 2) REACT scores “);
int testType = gaming console.nextInt();
come back testType;

public static int secondApplicant (Scanner console)

Method.out.println(“Information for your second consumer:”);
Method.out.print(“do you have 1) LAY sores and also 2) REACT scores “);
int testType = gaming console.nextInt();
come back testType;

public static dual satScore (Scanner console)

Method.out.print(“SAT math “);
double math = unit.nextDouble();
Method.out.print(“SAT verbal “);
double verbal = unit.nextDouble();
Method.out.print(“actual GPA “);
double gpa = system.nextDouble();
Method.out.print(“max GPA “);
double maxGPA = system.nextDouble();
double score = (2 * verbal + math) / 24;
double gpaScore = (gpa/maxGPA) * ONE HUNDRED;
double totalScore = report + gpaScore;
come back totalScore;

public static dual actScore(Scanner console)

Method.out.print(“ACT British “);
int british = system.nextInt();
Method.out.print(“ACT math “);
int math = system.nextInt();
Method.out.print(“ACT looking at “);
int looking at = system.nextInt();
Method.out.print(“ACT knowledge “);
int knowledge = system.nextInt();
Method.out.print(“actual GPA “);
double gpa = system.nextDouble();
Method.out.print(“max GPA “);
double maxGPA = system.nextDouble();
double score2 = (2 * reading + language + math + science) / JUST ONE.8;
double gpaScore2 = (gpa/maxGPA) * ONE HUNDRED;
double totalScore2 = gpaScore2 + score2;
come back totalScore2;

public static useless scoreComparison(double scoreOne, double scoreTwo)

Method.out.println(“First client overall fico score = ” + scoreOne);
Method.out.println(“Second client overall fico score = ” + scoreTwo);
whenever (scoreOne > scoreTwo)

Method.out.println(“The very first applicant seems to be better.”);

otherwise if (scoreOne == scoreTwo)

Method.out.println(“The tow people seem similar.”);

else

Method.out.println(“The next applicant seems to be better.”);

I made one or two modifications that may hopefully enable you to keep going with this.Have a great time!

signific java.util.*;

public class Own up

…..public static useless main(String args)
…..
……….Protection console = different Scanner(System.in);
……….introduction();
……….
……….double scoreOne, scoreTwo;
……….
……….if(applicant(console, “first”) == 1)
……………scoreOne = satScore(console);
……….otherwise
……………scoreOne = actScore(console);
……….
……….
……….Method.out.println();
……….
……….if(applicant(console, “second”) == 1)
……………scoreTwo = satScore(console);
……….otherwise
……………scoreTwo = actScore(console);
……….
……….
……….Method.out.println();
……….
……….scoreComparison (scoreOne, scoreTwo);
…..
…..
…..public static useless introduction()
…..
……….Method.out.println(“This course compares a couple of applicants to”);
……….Method.out.println(“determin what design seems like the stronger”);
……….Method.out.println(“applican Per candidate I’ll need”);
……….Method.out.println(“either LAY or REACT scores plus a weighted GPA.”);
……….Method.out.println();
…..
…..
…..public static int applicant (Scanner unit, String n)
…..
……….Method.out.println(“Informat for your ” + n + ” consumer:”);
……….Method.out.print(“do you have 1) LAY sores and also 2) REACT scores “);
……….int testType = gaming console.nextInt();
……….come back testType;
…..
…..
…..public static dual satScore (Scanner console)
…..
……….Method.out.print(“SAT math “);
……….double math = unit.nextDouble();
……….Method.out.print(“SAT verbal “);
……….double verbal = unit.nex

Leave a Reply