C# Array ToString
Description
Array ToString
returns a string that represents the current
object.
Syntax
Array.ToString
has the following syntax.
public virtual string ToString()
Returns
Array.ToString
method returns A string that represents the current object.
Example
using System;//from w ww . j a v a 2 s . co m
public class Example
{
public static void Main()
{
int[] myValuesizes = { 40, 5, 3, 22, 1, 18 };
Console.WriteLine(myValuesizes.ToString());
}
}
The code above generates the following result.