b. Names of all students whose test scores are below the average, with an appropriate message.
c. Highest test score and the name of all students having the highest score. Use two arrays to store the student names and scores respectively and then manipulate the array contents. import java.util.Scanner;
// for double formatting import java.text.DecimalFormat; public class StudentScore
{
//--------------------------------------------------------- // Calculate student score and basic report //--------------------------------------------------------- public static void main(String[] args) { // an array of double to store student's score double [] studentscore = new double[50]; // an array of String object to store student name String [] studentname = new String[50]; double studentavg = 0.0, sumscore = 0.0, averagescore = 0.0, highestscore =0.0; // index int i = 0, j = 0, k = 0, counter = 1; Scanner readname = new Scanner(System.in); Scanner readscore = new Scanner(System.in); // prompt for inputs: Student name and score System.out.println("Enter student name and score, 'Q' & 0 to stop: "); // read and store student name and score for 1st input... studentname[i] = readname.nextLine(); studentscore[i] = readscore.nextDouble(); // read and store next student name and score do { i++; counter++; System.out.println("Enter student name and score, 'Q/q' & 0 to stop: "); studentname[i] = readname.nextLine(); studentscore[i] = readscore.nextDouble(); // until the Q or q and 0 are entered... }