data structures and algorithm | Computer Science homework help

In this programming assignment you are asked to expand the SortedArrayList data structure we

have developed in class by adding the following new methods:

 void IncrementItems(T aValue)

– Function: Increments all lists’ values by aValue.

– Precondition: List has been initialized

aValue has been initialized

– Postcondition: Function value = elements of the list have their info incremented

by a Value.

 int CountEven()

– Function: Returns the number of elements that appears an even number of

times the list.

– Precondition: List has been initialized

– Postcondition: Function value = number of even integers in the list.

 void ReverseOrder ( )

– Function: Reverses the order of the list’s elements.

– Precondition: List has been initialized.

– Postcondition: Function value = elements changed to descending order, if

elements are in ascending order, and vice-vers

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes:

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>