Static Array Class

Learn to implement an array class and its methods.

Challenge

Write a program to create a class called array. Make a provision to perform the following operations on objects of this class:

Display: Prints all elements of an array

Search: Finds the location of an element with a given value

Insertion: Adds a new element to an array. This would shift the elements to the right. If some element already exists on the specified index, then the method should simply shift it to the right and insert a new element at that index.

Deletion: Removes an element from an array using its position. This would shift the elements to the left and set 0 in the place of a deleted element.

Reverse: Reverses the ...