Added split and merge example, and fixed bugs due to it!