I have an array of integers (val arr = intArrayof(6, 8, 11, 13)) and I want to set the values of the second and third elements equal to the values of another IntArray (val arr2 = intArrayOf(4, 7)),how do I do that?
I know I can set the values individually using the set method (arr.set(1, 4)) or with the index notation (arr[2] = 7) but is there a way to do it with a whole array/slice?
With Python I simply used slice notation, but that doesn't seem to work. Thank you