example 1, write 2d array
merging