Creating difference-of-sub-array