How do you make a java method removemaximumvalues


Problem

How do you make a java method removeMaximumValues(Node, int) using ONLY LinkedList (no Arrays, new Nodes or PriorityQueues)...

This method takes as parameters a linked list and an integer N and returns the linked list from which all instances of each of the N largest values in the input linked list have been removed. If the input value N is zero or negative, this method should simply return the list without modification. The other elements in the list should not be modified and their relative order must not be changed. Removing the N maximum values from an empty list should return the empty list for any value of N; an exception should not be thrown in this case, and in general you shouldn't throw exceptions unless we specify that you do so. Because the values are Strings, you will need to use the String class's compareTo method to compare.

Request for Solution File

Ask an Expert for Answer!!
JAVA Programming: How do you make a java method removemaximumvalues
Reference No:- TGS03302425

Expected delivery within 24 Hours