+ 1
can you add or insert values into an array, or does it have to be a stack?
3 Respuestas
+ 20
adding new items to array can be done through creating new array of needed length, copying old one there + new items; or just make another array and merge it with first one but that creates 3rd array... (look in my dices code)That's in case u want use only arrays
+ 3
an array's size is always a fixed length. so you cannot change the length. only change the values of the items. you can use a stack if you want, but a list would probably be better
+ 1
can you sum the int in a list?