From: "Ara.T.Howard" Date: 2004-02-20T20:21:17+09:00 Subject: Re: proposal: let kind_of take more arguments On Thu, 19 Feb 2004, Simon Strandgaard wrote: > Date: Thu, 19 Feb 2004 18:44:23 +0100 > From: Simon Strandgaard > Newsgroups: comp.lang.ruby > Subject: Re: proposal: let kind_of take more arguments > > On Thu, 19 Feb 2004 09:30:16 -0700, Ara.T.Howard wrote: > > On Thu, 19 Feb 2004, Simon Strandgaard wrote: > >> From: Simon Strandgaard > >> On Thu, 19 Feb 2004 08:19:33 -0700, Ara.T.Howard wrote: > >> > > >> > what do you reccomend (when a case won't do) ? > >> > > >> > ... > >> > unless choice.kind_of?(Zero) or choice.kind_of?(One) > >> > ... > >> > > >> > >> My brain is terrible at dealing with 'unless'. > >> If its just "unless something" then its ok. > >> But when its "unless a or b and c" then it chokes. > >> > >> Am I the only one feeling like this? > >> > >> Where can I seek help ? ;-) > > > > a digital logic book, the simplest, will help. de morgan's laws..., eg. > [snip talk about de morgans law] > > Yes I know these rules.. also karnough maps helps gaining overview of > boolean operations. When an expression gets too complex then I like > place a comment with the corresponding karnough map. > > What I should have said was that I grew up with 'if then else'. > The 'unless' keyword is a recent addition to my vocabulary, I am still > a bit rusty in its usage. ah. i got it from a the 'p' language - one of the good things about it IMHO. ;-) -a -- =============================================================================== | EMAIL :: Ara [dot] T [dot] Howard [at] noaa [dot] gov | PHONE :: 303.497.6469 | ADDRESS :: E/GC2 325 Broadway, Boulder, CO 80305-3328 | URL :: http://www.ngdc.noaa.gov/stp/ | TRY :: for l in ruby perl;do $l -e "print \"\x3a\x2d\x29\x0a\"";done ===============================================================================