Show pageOld revisionsBacklinksBack to top This page is read only. You can view the source, but not change it. Ask your administrator if you think this is wrong. # merge ### Syntax <code> (merge hmap1 hmap2) </code> {{ https://i.imgur.com/nqUW3a2.jpg }} ### Example <code> (ns clojure.examples.example (:gen-class)) (defn example [] (def demokeys (hash-map "z" 1 "b" 2 "a" 3)) (def demokeys1 (hash-map "a" 2 "h" 5 "i" 7)) (println (merge-with + demokeys demokeys1))) (example) </code> #### Output <code> {z 1, x 4, a 3, i 7, b 2, h 5} </code> ## Refs - https://www.tutorialspoint.com/clojure/clojure_maps_merge.htm open/merge.txt Last modified: 2024/10/05 06:15by 127.0.0.1