***mfiano_ is now known as mfiano
***alMalsamo is now known as lumberjack123
***karlosz__ is now known as karlosz
<dadinn>what's the best way to do boolean exclusive or in Guile? <dadinn>I have 5 values and it should be only true if only one of them is true <rlb>dadinn: depending on exactly what you want, perhaps convert the booleans to 0/1 and then (logxor v1 v2 v3 v4 v5). <rlb>and then convert back to boolean <dadinn>rlb: you mean there is no srfi or something else that already does this? <rlb>There might be, but not one that I know of for boolean variables. <rlb>I believe logxor is in some srfi(s), though. <rlb>(maybe under a different name - can't recall) <rlb>pinoaffe: ahh, right, thanks. <pinoaffe>dadinn: if I understand you correctly, you want something along the lines of (define (boolean-exclusive . args) (= 1 (length (filter values args)))) <dadinn>pinoaffe: regular or is not exclusive <dadinn>wingo: or sorry, regular or is not exclusive <dadinn>or sorry, just got mixed up in who wrote what :P <ArneBab>dadinn: not super beautiful, but should be correct: (equal? 1 (apply + (map (λ(x) (if x 1 0)) (list #f #f 9 #f #f))))