Provided the first bit of code for merge.