Skip to content

Instantly share code, notes, and snippets.

@nixoncode
Created April 24, 2020 14:37
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 nixoncode/c1c2e842342622c92b80e4965f0f034e to your computer and use it in GitHub Desktop.
Save nixoncode/c1c2e842342622c92b80e4965f0f034e to your computer and use it in GitHub Desktop.
dart test
void main() {
outer() {
var counter = 0;
incrementCounter() {
counter++;
print(counter);
}
return incrementCounter;
}
var myFunc = outer();
myFunc();
myFunc();
print(myFunc);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment