What is the easiest method of inserting and removing a value from an array?
Eg. I have an array of x number of values, and now I want to add one and have the array dimension grow, or I want to remove one and have the array dimension shrink.
[edit] forgot to mention that I want to add and remove values not just from the start and end of the array, but anywhere within the array. Otherwise slices should be good enough.
Eg. I have an array of x number of values, and now I want to add one and have the array dimension grow, or I want to remove one and have the array dimension shrink.
[edit] forgot to mention that I want to add and remove values not just from the start and end of the array, but anywhere within the array. Otherwise slices should be good enough.