-
-
Save onlyforbopi/d61282b1433b59164f9f303637a924ab to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1. List of anything | |
You can specify not only custom types. List<int>, List<double>, | |
List<string> will works as well. If you need to store mixed types - | |
you need to specify closest base class for all types. | |
In List<object> can be stored instance of any type. | |
If you are willing to give away type safety you can use an ArrayList, | |
which was the only way to use a list of stuff pre generics. | |
https://stackoverflow.com/questions/9184764/storing-different-types-inside-a-list |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment