Why not create a new prototype function for array that allows you to do this?