luni, 25 august 2014

Square brackets ([]) operator C#

Square brackets ([]) operator is used for arrays, indexers, and attributes.

Examples
 //arrays
  int[] mList;
  mList = new int[200];

 //indexers
  System.Collections.Hashtable h = new System.Collections.Hashtable();
  h["e1"] = 1; 
      
  //attributes
  [System.Serializable]

Niciun comentariu:

Trimiteți un comentariu