Basic Pascal Tutorial/Chapter 5/Multidimensional arrays/fr
Sent here from Multidimensional arrays/fr.
English · Français · Български · 中文(中国) · 日本語
Tutoriel de Pascal Objet : Types de données / Tableaux multidimensionnels
Vous pouvez avoir des tableaux à plusieurs dimensions :
type
datatype = array [enum_type1, enum_type2] of datatype;La virgule sépare les dimensions et faire référence au tableau, sera fait comme cela :
a [5, 3]Les tableaux à deux dimensions sont utiles pour les programmeurs de jeux de plateaux. Un plateau de morpion pourrait avoir les déclarations de types et de variables :
type
StatusType = (X, O, Blank);
BoardType = array[1..3,1..3] of StatusType;
var
Board : BoardType;Vous pouvez initialiser le plateau avec :
for count1 := 1 to 3 do
for count2 := 1 to 3 do
Board[count1, count2] := Blank;Vos pouvez, bien sûr, utiliser des tableaux à 3 dimensions ou plus encore.
From the Free Pascal wiki, page "Basic Pascal Tutorial/Chapter 5/Multidimensional arrays/fr", as it stood on 2022-08-20 after a change by Kai Burghardt, out of the wiki's dump of 2024-05-26. Copyright stays with the author who wrote it, according to the old wiki's Licensing page. If you have concerns about this material, message the admin.
Edited on wiki.freepascal.org by 5 people, 2014–2022
From the official wiki's backup of 26 May 2024: who edited this page there, and when. Edits made there after that date were not recorded, and the earlier versions are not shown here; the main page says why.
| When | Who | What changed |
|---|---|---|
| E-ric | Created page | |
| E-ric | ||
| E-ric | ||
| FTurtle | ||
| Frigory | Refonte | |
| Trev | Fixed syntax highlighting (minor) | |
| Trev | Text replacement - "Object Pascal Tutorial" to "Basic Pascal Tutorial" (minor) | |
| Kai Burghardt | Kai Burghardt moved page Multidimensional arrays/fr to Basic Pascal Tutorial/Chapter 5/Multidimensional arrays/fr: tidy up main name space: create subpage hierarchy for basic Pascal tutorial [cf. [[Sp... (minor) | |
| Kai Burghardt | bypass redirects [cf. discussion] | |
| Kai Burghardt | bypass language bar/categorization template redirect [cf. discussion] (minor) |
Talk about this page
Nobody has opened a bench for this page yet. Sign in to open one.
