METHOD

Array.Clone

Creates a shallow array copy. Reference-type element objects are not cloned.

Formal Syntax & Structure

csharp syntaxcsharp
(int[])values.Clone()

Working Example

Example Snippetcsharp
int[] values = { 1 }; int[] copy = (int[])values.Clone();
C# & .NET Reference