Warning: Use of undefined constant wp_cumulus_widget - assumed 'wp_cumulus_widget' (this will throw an Error in a future version of PHP) in /home/phme2432/public_html/wp-content/plugins/wp-cumulus/wp-cumulus.php on line 375
C-sharp ‹ What I Learned Today

What I Learned Today

No frills, just learn

Posts in the C-sharp category

C# Lists and Dictionary

In C# there are several key differences to C++. Microsoft Website spells them all: https://msdn.microsoft.com/en-us/magazine/cc301520.aspx

Garbage collector instead of deconstructors providing a different approach to micromenagment of memory and lists, jagged arrays and dynamic memory allocation are already available into the language. It supports also negative index to counting from the last element, similarly to Python.

About lists instead of the usual self-made textbook-example class, there are specific embedded classes for Lists and Dictionaries.

List<type> name = new List<type>();

Dictionary<type,type> name = new Dictionary<type,type>();