Skip to content

Instantly share code, notes, and snippets.

@gregworley
Created September 22, 2010 16:41
Show Gist options
  • Save gregworley/592043 to your computer and use it in GitHub Desktop.
Save gregworley/592043 to your computer and use it in GitHub Desktop.
package main
import "fmt"
func f() {
for i := 0; i < 10; i++ {
g := func(i int) {
fmt.Printf("%d", i)
}
g(i)
}
}
func main() {
f()
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment