Skip to content

Instantly share code, notes, and snippets.

@AnthonyDGreen
Created February 3, 2019 15:12
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 AnthonyDGreen/2ef9ba3dfcf9a1abe0e94b0cde12faf1 to your computer and use it in GitHub Desktop.
Save AnthonyDGreen/2ef9ba3dfcf9a1abe0e94b0cde12faf1 to your computer and use it in GitHub Desktop.
Module Program
Sub Main()
Dim lambdas = New List(Of Action)
For i = 1 To 3
Dim x As Integer
x -= 1
lambdas.Add(Sub() Console.WriteLine(x))
Next
For Each lambda In lambdas
lambda()
Next
End Sub
End Module
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment