Skip to content

Instantly share code, notes, and snippets.

@Sfshaza
Last active May 3, 2018 23:48
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Sfshaza/89d0fdf2de199f6909c2cc259ab61674 to your computer and use it in GitHub Desktop.
Save Sfshaza/89d0fdf2de199f6909c2cc259ab61674 to your computer and use it in GitHub Desktop.
Java-to-Dart codelab: Scream example - imperative code
String scream(int length) {
return "A${'a' * length}h!";
}
main() {
var values = [1, 2, 3, 5, 10, 50];
for (var length in values) {
print(scream(length));
}
}
@kwalrath
Copy link

kwalrath commented May 3, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment