An idiomatic way to get one of the possible values ​​on the map?

What is the best way to get the first nil value for several possible keys on the map.

Example:

(get-first-matching {:fum 4 :bar 41 :baz 45} [:foo :bar :baz]) ;=> 41 
+7
source share
1 answer

some .

 user=> (some {:fum 4 :bar 41 :baz 45} [:foo :bar :baz]) 41 
+11
source

All Articles