add into array func