Created
April 24, 2020 14:37
-
-
Save nixoncode/c1c2e842342622c92b80e4965f0f034e to your computer and use it in GitHub Desktop.
dart test
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
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