This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2018-03-14
Channels
- # aleph (2)
- # atlanta-clojurians (5)
- # beginners (38)
- # boot (2)
- # bristol-clojurians (1)
- # cider (31)
- # clara (8)
- # cljs-dev (136)
- # cljsrn (4)
- # clojure (86)
- # clojure-china (1)
- # clojure-greece (1)
- # clojure-italy (24)
- # clojure-nl (1)
- # clojure-spec (21)
- # clojure-uk (19)
- # clojurescript (68)
- # community-development (28)
- # core-async (35)
- # core-logic (4)
- # cursive (1)
- # data-science (1)
- # datascript (1)
- # datomic (46)
- # events (1)
- # figwheel (6)
- # fulcro (11)
- # graphql (3)
- # hoplon (1)
- # jobs (6)
- # jobs-discuss (94)
- # keechma (3)
- # luminus (4)
- # lumo (7)
- # mount (6)
- # off-topic (24)
- # onyx (6)
- # parinfer (31)
- # portkey (3)
- # programming-beginners (16)
- # re-frame (20)
- # reagent (69)
- # remote-jobs (4)
- # ring-swagger (25)
- # schema (1)
- # shadow-cljs (151)
- # spacemacs (2)
- # sql (14)
- # tools-deps (16)
- # uncomplicate (5)
- # unrepl (35)
- # vim (1)
- # yada (72)
månmån
mornings!
Morning
Curiosity got the better of me. Seeing some discussion which mentioned the FIZZBUZZ example so wrote it out quickly using map
and was curious how others here might tackle the solution differently?
(map
#(cond
(= 0 (mod % 3) (mod % 5)) "FIZZBUZZ"
(= 0 (mod % 3)) "FIZZ"
(= 0 (mod % 5)) "BUZZ"
:else %)
(range 1 101))
Think that's how I'd do it too 🙂
I might use zero?
- but it’s pretty readable
It slightly irks me that you might have to calculate (mod % [3|5])
more than once…
Hello stranger!
Another FP meetup in Horsham for anyone that might be able to make it (looking at you @mccraigmccraig😉) https://www.meetup.com/Horsham-Functional-Programming/events/248732589/
added to my diary @yogidevbear... not sure if i can yet - my calendar is subject to concurrent modifications and rollbacks