From: Tom Cloyd Date: 2009-01-05T10:22:10+09:00 Subject: Re: VERY simple question about "?" Todd Benson wrote: > On Sun, Jan 4, 2009 at 5:36 PM, Todd Benson wrote: > >> On Sun, Jan 4, 2009 at 5:06 PM, Tom Cloyd wrote: >> >>> Robert Klemme wrote: >>> >>>> 2009/1/4 Michael Guterl : >>>> >>>> >>>>> On Sun, Jan 4, 2009 at 9:48 AM, Robert Klemme >>>>> wrote: >>>>> >>>>> >>>> >>>>>> As far as I know there is no legal electronic version of the second >>>>>> edition >>>>>> so you better double check whether you are allowed to use this. You >>>>>> could >>>>>> as well buy the book to somewhat compensate for this. >>>>>> >>>>>> >>>>>> >>>>> http://www.pragprog.com/titles/ruby/programming-ruby >>>>> >>>>> There definitely is an option to select a PDF version for purchase. >>>>> >>>>> >>>> Thanks for the education! I wasn't aware of this. There was >>>> definitively an illegal PDF version offered (even here) in the past. >>>> >>>> Kind regards >>>> >>>> robert >>>> >>>> >>>> >>> I wouldn't engage with a illegitimate copy - isn't playing fair at all. I >>> completely believe in "intellectual property". My copy certainly WAS >>> purchased from the Pragmatic Programmers website. Marvelous book, of course, >>> but it does not, to my best knowledge, contain a complete list of operators. >>> I've done everything I can think of to find it. I seriously doubt that it's >>> there. The precedence table on 324 is about precedence, and not a primary >>> presentation of operators and their function. >>> >>> More incredibly, "operator" is not even in the index as a primary index term >>> - in the sense that I'm accustomed to the use of the word in programming >>> languages. >>> >>> Here's the entry that IS there: >>> >>> Operator >>> as method call 82, 335 >>> precedence 324 >>> >>> To me, this is simply strange. Dave Thomas, whose contributions to the Ruby >>> community are inestimably valuable, may see this thread, in which case I >>> hope he comments. I've been completely bewildered about this for a long >>> time. >>> >> Not sure if the following list is comprehensive, but useful nonetheless... >> >> http://www.zenspider.com/Languages/Ruby/QuickRef.html >> >> ...you'll find the first use of ? under Reserved words. >> > > I meant beneath Reserved words. It's actually classified under Types/Numbers. > > Todd > > > Definitely a useful page, about which I've known for some time. Outstanding for its brevity. Limited at times, because if you don't already know what he's talking about, you're not much enlightened by the page content at all. Two examples: * "Here docs" (right above "Symbols"). I know what this is, and I STILL cannot quickly make sense of the notes on the pages about this functionality. * Operators - has the same problem as Thomas' book: precedence is shown, but basic operator function appears to be assumed to be known. I'm sorry, but I wasn't born with that knowledge. Look at this line: <=> == === != =~ !~ There's some very strange stuff there. I'm only certain about the function of ONE of these, and I've been using Ruby for probably over a year an a half (remember - I'm an intermittent weekend programmer, of necessity). All that said, I find Ryan Davis's work simply amazing, and I'm very grateful for his presence in the world. His "Ruby QuickRef" at http://www.zenspider.com/Languages/Ruby/QuickRef.html#3 is likely supposed to be more cheat sheet than brief tutorial, to be fair. The best presentation of Ruby operators I've yet found (looking mostly on the web) is at http://www.tutorialspoint.com/ruby/ruby_operators.htm. Also good are those at http://www.techotopia.com/index.php/Ruby_Operators and http://www.devarticles.com/c/a/Ruby-on-Rails/Ruby-Operators-and-Arrays/. So, this stuff can be found, but you have to go looking for it. t. -- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Tom Cloyd, MS MA, LMHC - Private practice Psychotherapist Bellingham, Washington, U.S.A: (360) 920-1226 << tc@tomcloyd.com >> (email) << TomCloyd.com >> (website) << sleightmind.wordpress.com >> (mental health weblog) ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~