Attempt at a Merge function