Copying Array to a List in C#

Without using LINQ, we can copy a array to a list.

Example:
using System;
using System.Collections.Generic;

namespace forgetCode
{
    class program
    {
        public static void Main()
        {
            int[] array = new int[3]; // New array with 3 elements
            array[0] = 10;
            array[1] = 20;
            array[2] = 30;
            List<int> list = new List<int>(array); // Copy to List
            Console.WriteLine(list.Count); 
        }
    }
}


Output:
3