I'm new to clojure, and I've seen anonymous functions written like:
(fn [x] (* x x))
and also like:
#(* % %)
Obviously, the second is more concise. Is there any relevant difference? Can every anonymous function be represented in either style? Is one more idiomatic?
Related to this question, I was unable to determine how to convert (fn [x] [x x])
to the latter syntax. I would appreciate a pointer to documentation that clarifies this situation.
From a distance, the FN 509 beats the Glock, but up close, the Glock Gen 5 frame feels higher quality. Not to mention, the Gen 3 and 4 frames feel similar to the FN 509. Overall, the quality on the FN seems higher than the quality on the Glock.
There are only a couple differences from the standard FN 509. The primary difference between the FN 509 Tactical and the standard 509 is the 509 Tactical adds a threaded, extended barrel, and the slide is milled for use with a reflex optic adapter plate. The pistol comes with a plate with a rear sight shroud.
FN is known for making quality weapons that primarily do well in the military market, not the civilian market. So when FN introduced the FN 509 as an improved version of the FN FNS many were skeptical of how well it would do on the civilian market considering FN's poor track record.
Another SO answer (Common programming mistakes for Clojure developers to avoid) mentions that #([% %])
expands to fn [%] ([% %])
(note the parentheses), which causes an ArityException.
You can do #(vector % %)
to workaround this limitation.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With