Created
January 13, 2017 22:20
-
-
Save bamchoh/02505e37b94f3c35b1efeb2e79e4a577 to your computer and use it in GitHub Desktop.
This file contains 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
package main | |
import "fmt" | |
func tap(v []int) []int { | |
fmt.Println(v) | |
return v | |
} | |
func main() { | |
v := []int{1, 2, 3, 4} | |
for i := range tap(v) { | |
v = append(v, i) | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment