Moved array utils into its own file.