Hi Team,
I am having array of length 8. Array = [1,2,3,4,5,6,7,8]
After picking 2 from array, I am able to get the remaining part using splice function. [1,3,4,5,6,7,8]
But, it is changing the original array also to the same value.
I have tried to make copy of array which is having reference of original array. But, even in this case it is changing the original value of array.
How can I retain the original array?
Thank you!