draft of array functions