c# - How can I repopulate an array? -


i have code populates array:

var counters = new[] { 1,2,4,8 } 

this works later on in code this:

counters = new[] { 2,2,3,5 } 

is there way can this? new c# , still learning

the code wrote in question work fine: first line create new array, second line create new array , assign new array existing variable. old integer array replaced (and later garbage collected)


Comments

Popular posts from this blog

Cursor error with postgresql, pgpool and php -

delphi - ESC/P programming! -

c++ - error: use of deleted function -