What is a two dimensional array or matrix?
A two dimensional array consists of: – a finite, – ordered set of elements – of the same data type. Two dimensional arrays OR matrices are declared in the same way as normal arrays: var arrNames : array[1..20, 1..20] of String; arrAges : array[1..5, 1..1000] of Integer; The array arrNames can contain up to 20 names (String data type) under 20 headings. The array arrAges can contain up to 1000 integer values under 5 headings. We can therefore say when declaring a 2D array or Matrix the first range is the column and the second the different rows. This is also true for the StringGrid component.