updated my algorithm as it wasn't removing the right indexes from the second list.