Get the value at the specified position in the one-dimensional Array in CSharp
Description
The following code shows how to get the value at the specified position in the one-dimensional Array.
Example
using System;//ww w .j ava 2s . com
public class SamplesArray {
public static void Main() {
String[] myArr1 = new String[5];
myArr1.SetValue( "three", 3 );
Console.WriteLine( "[3]: {0}", myArr1.GetValue( 3 ) );
}
}
The code above generates the following result.