Re: ifficiency [sic]

2006-05-23 Thread Darrin Chandler
On Mon, May 22, 2006 at 08:36:39PM -0400, Ryan Flannery wrote: > On 5/22/06, prad <[EMAIL PROTECTED]> wrote: > >this is not openbsd specific, but i wanted to ask people who really > >understand > >the inner workings of programming languages. > > > >suppose that you have 2 conditions A and B where

Re: ifficiency

2006-05-23 Thread Tony Abernethy
Nick Guenther wrote: > > On 5/23/06, prad <[EMAIL PROTECTED]> wrote: > > On Monday 22 May 2006 17:54, you wrot > > > You can consider short-circuiting of Boolean evaluation > greedy, but it a > > > feature which may also save clock cycles if the right-most > sub-expressions > > > are costly to eval

Re: ifficiency

2006-05-22 Thread Liviu Daia
On 23 May 2006, <[EMAIL PROTECTED]> wrote: > Original message from prad <[EMAIL PROTECTED]>: > > > suppose that you have 2 conditions A and B where B take a lot of > > effort to determine (eg looking for a string match in a huge file). > > > > either A or B needs to be true before you can exec

Re: ifficiency

2006-05-22 Thread Nick Guenther
On 5/23/06, prad <[EMAIL PROTECTED]> wrote: On Monday 22 May 2006 17:54, you wrot > You can consider short-circuiting of Boolean evaluation greedy, but it a > feature which may also save clock cycles if the right-most sub-expressions > are costly to evaluate. > thanks to all for the responses! wh

Re: ifficiency

2006-05-22 Thread jjhartley
Original message from prad [EMAIL PROTECTED]: > On Monday 22 May 2006 17:54, you wrote: > ... > i was puzzled reading something on one of the wikipedia links provided: > "The opposite of lazy evaluation is eager evaluation, also known as strict > evaluation. Eager evaluation is the evaluation be

Re: ifficiency

2006-05-22 Thread prad
On Monday 22 May 2006 17:54, you wrot > You can consider short-circuiting of Boolean evaluation greedy, but it a > feature which may also save clock cycles if the right-most sub-expressions > are costly to evaluate. > thanks to all for the responses! what a great list!! using the links and explana

Re: ifficiency

2006-05-22 Thread jjhartley
Original message from prad <[EMAIL PROTECTED]>: > suppose that you have 2 conditions A and B where B take a lot of effort to > determine (eg looking for a string match in a huge file). > > either A or B needs to be true before you can execute 'this'. > > the 2 if statements below are equival

Re: ifficiency

2006-05-22 Thread Martin Schröder
See http://en.wikipedia.org/wiki/Minimal_evaluation Best Martin

Re: ifficiency

2006-05-22 Thread Ryan Flannery
On 5/22/06, prad <[EMAIL PROTECTED]> wrote: this is not openbsd specific, but i wanted to ask people who really understand the inner workings of programming languages. suppose that you have 2 conditions A and B where B take a lot of effort to determine (eg looking for a string match in a huge fi

ifficiency

2006-05-22 Thread prad
this is not openbsd specific, but i wanted to ask people who really understand the inner workings of programming languages. suppose that you have 2 conditions A and B where B take a lot of effort to determine (eg looking for a string match in a huge file). either A or B needs to be true before