﻿//Visual Basic 2012 Inleiding Arrays Arrays public class Exercise6Solution { void Main() { int count = 10; int upperbound = (count - 1); int[] values1 = new int[0]; int[] values2 = new int[0]; int[] values3 = new int[0]; int index; this.values1(index) = (index + 1); Console.WriteLine("Array 1 :"); Console.WriteLine(((((("element " + (index + 1)) + " (index ") + index) + ") : ") + this.values1(index))); Console.WriteLine(); this.values2(index) = (count - index); Console.WriteLine("Array 2 :"); Console.WriteLine(((((("element " + (index + 1)) + " (index ") + index) + ") : ") + this.values2(index))); Console.WriteLine(); if ((this.values1(index) >= this.values2(index))) { this.values3(index) = this.values1(index); } else { this.values3(index) = this.values2(index); } Console.WriteLine("Array 3 :"); Console.WriteLine(((((("element " + (index + 1)) + " (index ") + index) + ") : ") + this.values3(index))); Console.WriteLine(); Console.ReadLine(); } } //Bezoek www.vbvoorbeelden.be voor meer C# voorbeelden. //Copyright - De Wolf / vbvoorbeelden - 2003-2012 - Alle rechten voorbehouden.