adds intersection of two array code