📜  c# new 关键字 - C# 代码示例

📅  最后修改于: 2022-03-11 14:49:13.407000             🧑  作者: Mango

代码示例1
The new operator creates a new instance of a type.
  
In the example below an object is created for the class using the new.
   Calculate c = new Calculate();

You can also use the new keyword to create an instance of the array.
  double[] points = new double[10];

The new keyword is also used to create object of a collection.
  SortedList sl = new SortedList(); // SortedList
  List myList = new List() // List