Re: more on Cryptarithm test

1999-09-28 Thread Fergus Henderson
On 27-Sep-1999, S.D.Mechveliani [EMAIL PROTECTED] wrote: -- C++ - ... int condition2 (vectorlong x) {int i = 0; while ( i 20x[i]==9-i ) i++; That has undefined behaviour, since your vector `x' only has length 10, not 20. I

Re: more on Cryptarithm test

1999-09-28 Thread Fergus Henderson
On 27-Sep-1999, D. Tweed [EMAIL PROTECTED] wrote: One small comment is that in your functions condition1 condition2 I think most C++ programmers would say that you want to write int condition1 (const vectorlong x) since otherwise the compiler generally has to obey the normal function

Re: more on Cryptarithm test

1999-09-27 Thread Manuel M. T. Chakravarty
[EMAIL PROTECTED] (S.D.Mechveliani) wrote, As to me, i still agree to pay 17 times for the functionality. But is the test all right, what people think? And he compared the Haskell program with the C++ program that uses the next_permutation function. If you don't know the implementation of

more on Cryptarithm test

1999-09-27 Thread S.D.Mechveliani
To my letter on the Cryptarithm test (proposed by Mark Engelberg [EMAIL PROTECTED] ) [..] As to me, i still agree to pay 17 times for the functionality. But is the test all right, what people think? And he compared the Haskell program with the C++ program that uses the next_permutation

Re: more on Cryptarithm test

1999-09-27 Thread D. Tweed
On Tue, 28 Sep 1999, Fergus Henderson wrote: Personally I'd always write the above, not so much for performance reasons as the fact that if the objects in the vector have a shallow copy constructor (generated automatically silently) but a destructor that deallocates resources you've

Re: more on Cryptarithm test

1999-09-27 Thread D. Tweed
On Mon, 27 Sep 1999, S.D.Mechveliani wrote: Now it shows the ratio * 6 *. [snip] But this mess with platforms and versions, is not, probably, so important, because people can compile and run this program in their own environments - and correct the performance result. What do you