Overload generic method DisplayArray of Fig so that it takes two additional int arguments: lowlndex and highlndex.
Fantastic news! We've Found the answer you've been seeking!
Question:
Overload generic method DisplayArray of Fig so that it takes two additional int arguments: lowlndex and highlndex. A call to this method displays only the designated portion of the array. Validate lowlndex and highlndex. If either is out of range, or if highlndex is less than or equal to lowlndex, the overloaded DisplayArray method should throw an InvalidlndexException; otherwise, DisplayArray should return the number of elements displayed. Then modify Main to exercise both versions of DisplayArray on arrays intArray, double-Array and charArray. Test all capabilities of both versions of DisplayArray.
Related Book For
Principles of Taxation for Business and Investment Planning 2016 Edition
ISBN: 9781259549250
19th edition
Authors: Sally Jones, Shelley Rhoades Catanach
Posted Date: