Useful utility methods for arrays