»lookup Function

lookup retrieves the value of a single element from a map, given its key. If the given key does not exist, a the given default value is returned instead.

lookup(map, key, default)


> lookup({a="ay", b="bee"}, "a", "what?")
> lookup({a="ay", b="bee"}, "c", "what?")

»Related Functions

  • element retrieves a value from a list given its index.