Q)Write a menu driven program to input elements in a list and perform the following operations: (ii) Replace each element having even value with its half and each element having odd value(except first value) with double of its previous position element.