every? expected behavior

2014-04-08 Thread Jeff Mad
Hi, I am new to Clojure, so please forgive me if this does not make sense. I was surprised to find out in the REPL that every? returns true if you pass in an empty or nil collection. user=> (every? #(= 77 %) nil) true user=> (every? #(= 77 %) '()) true I looked at the source for every?

Re: every? expected behavior

2014-04-08 Thread Jeff Mad
r more info check out http://en.wikipedia.org/wiki/Vacuous_truth. > > On Tuesday, 8 April 2014 07:08:56 UTC+1, Jeff Mad wrote: >> >> Hi, >> I am new to Clojure, so please forgive me if this does not make sense. >> >> I was surprised to find out in the REPL that every? re

usage of "and"

2015-09-06 Thread Jeff Mad
I am reading Clojure Applied, which I am enjoying. One code snippet is puzzling for me, can someone please explain why the authors used: (and (pos? cnt) instead of just (pos? cnt) ? Or to go further, (pos? (item @inventory)) The best I could think is that there used to be a check for two th

Re: Using cookies with clj-http.client

2015-11-09 Thread Jeff Mad
I don't see any problem with your code. Try to add :debug true to both of those maps and look at the output. Ensure that for both URLs share exact same hostname and protocol http/https. Look at the Set-Cookie header in the POST response and ensure that the path matches the url in the GET. On

Re: ANN metrics-clojure 2.6.0 is released

2015-12-01 Thread Jeff Mad
Congratulations, I look forward to using this, upgrading to 3.1 is great and the features on the release notes (really nice to have clear, concise release notes) will make using it much better. On Monday, November 30, 2015 at 10:30:10 AM UTC-8, Michael Klishin wrote: > > metrics-clojure is a C