search element in array using linear search