Last active
May 26, 2017 08:41
-
-
Save christiannagel/0e1fb6bdee17f02f5cbc8c417a68e82f to your computer and use it in GitHub Desktop.
Allocate and use a simple array
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private static void UsingSimpleArrays() | |
{ | |
Console.WriteLine(nameof(UsingSimpleArrays)); | |
for (int i = 0; i < 20; i++) | |
{ | |
LocalUseOfArray(i); | |
} | |
Console.WriteLine(); | |
Console.WriteLine(); | |
} | |
private static void LocalUseOfArray(int i) | |
{ | |
int[] arr = new int[ARRAYSIZE]; | |
ShowAddress($"simple array {i}", arr); | |
FillTheArray(arr); | |
UseTheArray(arr); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment