This shows you the differences between two versions of the page.
alf:laboratoare:00_fr_java [2023/02/27 11:46] cristiana.andrei [Excercices] |
alf:laboratoare:00_fr_java [2023/02/27 15:44] (current) cristiana.andrei [Types de données] |
||
---|---|---|---|
Line 41: | Line 41: | ||
* **array**: liste de valeurs ayant le meme type et une taille fixe | * **array**: liste de valeurs ayant le meme type et une taille fixe | ||
<code java> | <code java> | ||
- | int[] numbers = [1, 2, 3]; | + | int[] numbers = {1, 2, 3}; |
- | String[] words = ["some", "strings", "here"]; | + | String[] words = {"some", "strings", "here"}; |
</code> | </code> | ||
* **enums**: Un type spécial de classe qui représente un groupe des constantes | * **enums**: Un type spécial de classe qui représente un groupe des constantes |