Free Pascal Program Tutorial 18 - Arrays - Lazarus

Опубликовано: 13 Май 2012
на канале: SchoolFreeware
86,126
536

http://www.schoolfreeware.com

Arrays hold lists of variables of the same data type. When there are large lists of variables and data, it is easier to contain the data in an array than have large amounts of separate variables to hold the data. Think of an array as a placeholder for piece of data.


The syntax of the array is:

Name_Of_Array : array[range] of datatype;

For example if we wanted to create an array that will hold five human first names the syntax will look like this:

FirstName : array[1..5] of string;