Created
May 8, 2022 22:03
-
-
Save bakate/11e7ed79e7a79a909b3c06b97e7ec377 to your computer and use it in GitHub Desktop.
How to create a list in Dart
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const myList = ["Simon", "Brieuc", "Romain", "Antoine a.k.a DJ Dragon", "Aurel", "Séb", "Nadhir", "Carl", "Rachida", "Julien"]; | |
void main() { | |
myList.forEach(displayElement); | |
} | |
void displayElement(String element) { | |
print(element.toUpperCase()); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment