```ts
/** The values with every negative number removed. */
export function removeNegatives(values: readonly number[]): number[] {
  const result = [...values]; // Create a copy of the input array to avoid mutation
  for (let i = 0; i < result.length; i++) {
    if (result[i] < 0) {
      result.splice(i, 1); // Only remove negative numbers, not other elements
      i--; // Adjust index after removal to account for shifting of elements
    }
  }
  return result;
}
```