I'm trying to pick up C# and have been doing some practice programs. In this one, I try to transfer the integers in practiceArray to practiceArray2 but am unsuccessful, instead obtaining this as the output:
System.Int32[]
System.Int32[]
The code of my program is as follows:
static void Main(string[] args)
{
int[] practiceArray = new int[10] {2,4,6,8,10,12,14,16,18,20 };
int[] practiceArray2 = new int[practiceArray.Length];
for (int index = 0; index < practiceArray.Length; index++)
{
practiceArray2[index] = practiceArray[index];
}
Console.WriteLine(practiceArray);
Console.WriteLine(practiceArray2);
}