Modified splice()