Given an array of numbers, the task is to find all combinations of three numbers from the array such that their sum equals a given target value.
There are several ways to remove elements from an array, each with its own advantages and disadvantages. It's generally recommended to use the splice() or filter() method.