int[] numbers = {1, 2, 3, 4, 5};
for(int i = 0; i < numbers.Length; i++) {
  Console.WriteLine(numbers[i]);
}

foreach(int num in numbers) {
  Console.WriteLine(num);
}
Comments