Skip to content

Instantly share code, notes, and snippets.

@mattetti
Created July 29, 2015 04:17
Show Gist options
  • Select an option

  • Save mattetti/a5576705217642c1c437 to your computer and use it in GitHub Desktop.

Select an option

Save mattetti/a5576705217642c1c437 to your computer and use it in GitHub Desktop.
package main
import "fmt"
func main() {
type key struct {
door string
}
keys := []key{key{door: "x"}, key{door: "y"}, key{door: "z"}}
fmt.Print(keys[0])
// find the key to open door y
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment