Need help solving this step by step so I can understand it. Prom n the user to e
ID: 3861112 • Letter: N
Question
Need help solving this step by step so I can understand it. Prom n the user to enter the integer scores for Exam I·Exam 2 and Final Eurn read the scores compute the weighted average sooee (usmgthe follo ing fem la, and diplay a labeled o dabout de weigh davenge 128 637 3 307 1024 inScore 2 IMPORTANT: For the purpose of this exercise, be sure to observe the following You perform ein the apropriate or er ofe and the ak itions. m nlications and divsi ns shenintheprven fin You MUST use Mahoma g to emeet maltiplwatsons and divis es involving power, of , nala lin.hMNn "es new h b ains m wypert nina i the computation more efficiest) Note that 2. 12S and 1024 correspond to some power, of 2 cht ni007 and 63n discard the fractional portion when a division is perfonmed. When evaluating the firr and cd on the right hard sie (e, the Esam and sam 2 eceributions, respectivelyk Assume n is the intent to simply discard the f actional portion when a din isim i, per homever, you MUIST perfom (in each case) the divisice aer (hMoT Afhr) the maliplicalion fotherwie, aracy may he umecesanily kasth For my multiplwatin anl division eperation that cannot be effected with imple anname) be that caenobe enoted with le.one-time) bn.shuning, you MAT--her-rw"mmwi-e r·Explanation / Answer
E's below are replaced with the particular ArrayList’s element type. void addtg item) // Adds the specified item to the end of this list. void addtint index, g item)// Adds the specified item by inserting it into this // list at the specified index. boolean contains(§ item)// Returns true iff the specified item is in this list, // otherwise false. g gettint index) // Returns the item at the specified index in this list. int index0f(§ item) // Returns the index of the specified item if it is in // this list, or "1 if the item is not in this list. E remove(int index) // Removes and returns the item from the specified index. Boolean removetg item) // Returns true iff the specified item was removed from // this list, otherwise false. int size() // Returns the number of used elements in this list. Methods from the java . lang . Math class: double random () fchturus a random value between 0 (inclusive) and I (exclusive). double pow(double x, double n) l/Returns x raised to the n—th power double sqrt(double n) l/Returns the square root n. double abs(double n) //Returns the absolute value of n. double ceil(double n) //Returns the value of n rounded up to the nearest //whole number. Methods from the java . util . Random class: Random() //Creates a new random number generator. Randomlint s) //Creates a new random number generator seeded with 5. int nextInt(int n) //Returns the next pseudo~random integer value //between 0 (inclusive) and n (exclusive). double nextDouble() //Returns the next pseudo—random double value //between 0.0d (inclusive) and 1.0d (exclusive). Methods from the java . util . Scanner class: ScannertSystem.in) // Creates a Scanner object that reads from the keyboard. boolean hasNext() // Returns true if there's another token of input. boolean hasNextDoublet) // Returns true if the.next input is a double value. boolean hasNextInt() // Returns true if the next input is an int value. boolean hasNextLinet) // Returns true if there‘s another line of input. String next() // Returns the next token of input. double nextDouble() // Scans the next token of the input as a double. int nextInt() // Scans the next token of the input as an int. String nextLine() // Returns the next line of input as a String. Methods from the java . lang . String class (*REMEMBER -hased indexing is used): StringtString str) // Creates a String object given another string. char charAttint index) // Returns the char value at the specified index. boolean contains(string s)// Returns true iff string 5 is in this string, // otherwise false. boolean equals(String s)// Returns true iff the contents of this string // is the same as that of string s. boolean equalsIgnoreCase(String s)// Returns true iff the contents of the // this string is the sameLas the the // string s, ignoring differences in case. int index0f(string s) // Returns the index wit in this 5 ring of t e irs // character of the first occurrence of the specified string 6. Returns the length of this string. Returns a new string that is the lowercase version of this string. Returns a new string that is the UPPERCASE version of this string. int length() String toLowerCase() String toUpperCase()