Skip to main content

update

functionv1.7

clojure.core/update

Available in:BBCLJCLJS
(update [m k f] [m k f x] [m k f x y] [m k f x y z] [m k f x y z & more])
'Updates' a value in an associative structure, where k is a key and f is a function that will take the old value and any supplied args and return the new value, and returns a new structure. If the key does not exist, nil is passed as the old value.

No examples yet. Be the first to add one!