ClojureDocs

Nav

Namespaces

Clojure/Conj 2026 — Charlotte, NC — Sept 30 - Oct 2 Learn More & Get Tickets →

update-in

clojure.core

Available since 1.0 (source)
  • (update-in m ks f & args)
'Updates' a value in a nested associative structure, where ks is a
sequence of keys and f is a function that will take the old value
and any supplied args and return the new value, and returns a new
nested structure.  If any levels do not exist, hash-maps will be
created.