Array.duplicate() monkey patch