Maurice Tutor

(5)

$15/per page/Negotiable

About Maurice Tutor

Levels Tought:
Elementary,Middle School,High School,College,University,PHD

Expertise:
Algebra,Applied Sciences See all
Algebra,Applied Sciences,Biology,Calculus,Chemistry,Economics,English,Essay writing,Geography,Geology,Health & Medical,Physics,Science Hide all
Teaching Since: May 2017
Last Sign in: 398 Weeks Ago, 3 Days Ago
Questions Answered: 66690
Tutorials Posted: 66688

Education

  • MCS,PHD
    Argosy University/ Phoniex University/
    Nov-2005 - Oct-2011

Experience

  • Professor
    Phoniex University
    Oct-2001 - Nov-2016

Category > Computer Science Posted 15 Sep 2017 My Price 9.00

Queue of Integers

  1. Write a method named filterOnMax that takes a Queue of Integers and an integer value named max as parameters and returns a new Queue of Integers that contains only the values in the original queue that are less than or equal to the value of max. The new Queue should preserve the order of the old Queue, and the old Queue should be empty when this method is finished. There is no guarantee that the values in the input Queue will be sorted. Your method should display an understanding of FIFO Queue processing so make sure your code uses only Queue operations on the Queue objects (add, remove, and peek). Your method should use the following header: public static Queue<Integer> filterOnMax(Queue<Integer> input, int max)
  2. Write a method named filterOutVowels that takes a Stack of Characters and returns a new Stack of Characters that contains only the values in the original Stack that are not vowels ('a','e','i','o','u'). When the method is complete, the original Stack should be empty. The new Stack must have its elements in the same order as the original Stack, so you will need to do something to preserve the order of the original Stack as you are making your choices (hint - you will want to use a third Stack beyond just the input and output Stacks). Your code should work for capital or lowercase letters (so you may want to use the methods Character.toUpperCase or Character.toLowerCase in your code). Your method should display an understanding of Stack processing, so make sure your code uses only Stack operations on your Stack objects (push, pop and peek). Your method should use the following header: public static Stack<Character> filterOutVowels(Stack<Character> input)
  3. Think back to your knowledge of mathematical Set operations. The union of two Sets A and B is everything that is in Set A along with everything that is in Set B with no duplicates. For example, if Set A contained {'A','C','D'} and Set B contained {'A','B','C'} then the union of A and B would contain {'A','B','C','D'}. Write a method named union that takes two Sets of Integers as parameters A and B and returns a new Set of Integers that contains the union of A and B. The original Sets A and B should be the same after the method is finished as they were when the method started.
  4. Continuing on from problem 5, the intersection of two Sets A and B is everything that is in both of the Sets A and B. For example if Set A contained {'A','C','D'} and Set B contained {'A','B','C'} then the intersection of A and B would contain {'A','C'}. Write a method named intersection that takes two Sets of Integers as parameters A and B and returns a new Set of Integers that contains the intersection of A and B. The original Sets A and B should be the same after the method is finished as they were when the method started.

Answers

(5)
Status NEW Posted 15 Sep 2017 03:09 PM My Price 9.00

Hel-----------lo -----------Sir-----------/Ma-----------dam-----------Tha-----------nk -----------You----------- fo-----------r u-----------sin-----------g o-----------ur -----------web-----------sit-----------e a-----------nd -----------and----------- ac-----------qui-----------sit-----------ion----------- of----------- my----------- po-----------ste-----------d s-----------olu-----------tio-----------n.P-----------lea-----------se -----------pin-----------g m-----------e o-----------n c-----------hat----------- I -----------am -----------onl-----------ine----------- or----------- in-----------box----------- me----------- a -----------mes-----------sag-----------e I----------- wi-----------ll

Not Rated(0)