go-tour/defer-multi.go
2020-02-04 21:44:36 -06:00

14 lines
164 B
Go

package main
import "fmt"
func main () {
fmt.Println("counting")
for i := 0; i < 10; i++ {
defer fmt.Println(i)
}
fmt.Println("done")
}