Skip to content

Instantly share code, notes, and snippets.

@matthaliski
Last active August 13, 2020 15:01
Show Gist options
  • Save matthaliski/2ec67aa5f96e8d4d3be37dd734ce0ff6 to your computer and use it in GitHub Desktop.
Save matthaliski/2ec67aa5f96e8d4d3be37dd734ce0ff6 to your computer and use it in GitHub Desktop.
Note about Arrays

Arrays and Lists

Arrays

Arrays are a little bit different in c# than they are in most other languages and they basically suck. Main reason: they're fixed length. In order to make an array longer you basically have to copy the contents of the old array into a newer, longer array that also has a fixed length.

There are a few instances where arrays may be slightly more performant, but the c# community seems to favor lists for almost all occasions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment