This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision Next revision | Previous revision | ||
|
in202:seance_3:td_3:part_i [2021/04/08 07:28] bmonsuez [Question 1.4] |
in202:seance_3:td_3:part_i [2022/11/18 10:46] (current) |
||
|---|---|---|---|
| Line 36: | Line 36: | ||
| <code cpp> | <code cpp> | ||
| - | int[8] arrayOfIntegers = {2, 4, 3, 7, 1, 8, 9, 5 }; | + | int arrayOfIntegers[8] = {2, 4, 3, 7, 1, 8, 9, 5 }; |
| - | float[6] arrayOfFloats = {1.3, 3.4, 2.3, 4.7, 1.9, 7.2 }; | + | float arrayOfFloats[6] = {1.3, 3.4, 2.3, 4.7, 1.9, 7.2 }; |
| </code> | </code> | ||
| Line 62: | Line 62: | ||
| }; | }; | ||
| - | Point* = arrayOfPoints[] = { Point(2,3), Point(4,5), Point(0,0), Point(7, 8) }; | + | Point arrayOfPoints[4] = { Point(2,3), Point(4,5), Point(0,0), Point(7, 8) }; |
| </code> | </code> | ||
| Line 69: | Line 69: | ||
| Expliquer le résultat. | Expliquer le résultat. | ||
| + | |||
| + | ==== Code présenté pendant le cours ==== | ||
| + | |||
| + | {{https://perso.ensta-paris.fr/~bmonsuez/Media/code/in202/2021/td3/part1/part1.cpp|''part1.cpp''}} Fichier principal contient les fonctions de test et le main. | ||
| + | |||
| + | {{https://perso.ensta-paris.fr/~bmonsuez/Media/code/in202/2021/td3/part1/find.h|''find.h''}} Définition de la fonction générique de recherche. | ||
| ==== Liens vers les éléments syntaxiques C++ ==== | ==== Liens vers les éléments syntaxiques C++ ==== | ||