Guest User

Untitled

a guest
Nov 4th, 2019
95
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.39 KB | None | 0 0
  1. (def myMap {
  2. :first {
  3. :name "John",
  4. :age "17"
  5. },
  6. :second {
  7. :name "Bill",
  8. :age "27",
  9. :height "150"
  10. },
  11. :third {
  12. :name "Alicia",
  13. :height "150"
  14. }
  15. })
  16.  
  17. (defn printMap2 [myKey myValue]
  18. (do
  19. (dissoc myMap (for [iKey (keys myMap)]
  20. (if (=((myMap iKey) myKey) myValue) iKey))
  21. )
  22. )
  23. )
  24.  
  25. (println (printMap2 :height "150"))
Advertisement
Add Comment
Please, Sign In to add comment