Skip to content

Instantly share code, notes, and snippets.

@jmuzsik
Last active November 19, 2017 01:26
Show Gist options
  • Save jmuzsik/a959a5fae6d7d9c01e25f930485e2e7f to your computer and use it in GitHub Desktop.
Save jmuzsik/a959a5fae6d7d9c01e25f930485e2e7f to your computer and use it in GitHub Desktop.
func (c Clone) findExit(m Maze) TheMeaningOfLife {
var currentLocation string
if len(m.location.props.next) == 3 {
currentLocation = &c.goDifLocation(
m.Location.props.next[rand.Intn(
len(m.location.props.next))])
}
//... etc.
if currentLocation == m.location.props.final {
return TheMeaningOfLife
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment