code: def associn(m, path, value):
      
      def assoc_recursively(m, path, value):
          if not path:
              return value
          p = path[0]
          return assoc(m, p, assoc_recursively(m.get(p,{}), path[1:], value))
      return assoc_recursively(m, path, value)
docs: Copy-on-write associates a value in a nested dict