Okay, as disciple pointed out to me, his example will work, $a-- is a POST-decrement, so it gets the true value of $a first, and THEN subtracts one. For whatever reason I saw pre-decrement. Not enough caffeine or something. :)
Patrick > -----Original Message----- > From: Patrick Gaskill [mailto:[EMAIL PROTECTED]] > Sent: Wednesday, May 22, 2002 04:32 PM > To: 'Fun With Perl ([EMAIL PROTECTED])' > Subject: RE: shortest test for truth & false assignment > > > Ah, but did you try running this? "$a--" will be false, > meaning it will > short-circuit, and never get to do_something(). > > > -----Original Message----- > > From: disciple [mailto:[EMAIL PROTECTED]] > > Sent: Wednesday, May 22, 2002 04:35 PM > > To: [EMAIL PROTECTED] > > Subject: RE: shortest test for truth & false assignment > > > > > > The more obscure looking the better... > > > > $a&&$a--&&do_something(); > > >
