adding an element in array