On 6/12/07, Roger Hui <[EMAIL PROTECTED]> wrote:
> Note also that Roger's solution provides answers of the same length
> in all cases other than 1 2 3 4 5 6.

I don't understand what you mean by that.
My "solve" produces the following answers (as
from my msg):

  solve 1 3 2 6 5 4
1 2 1
  solve 5 6 2 1 4 3
0 2
  solve 6 5 4 1 2 3
0 1 2

In what way are 0 2 and 1 2 1 answers of the same
length?

What I meant was that the answers produced by your "solve"
have the same length as the answers produced by my "solve",
except when the argument is 1 2 3 4 5 6.  In other words, in
all but that trivial case your answers are as short as the minimal
length answers.

For that case, my solve returns an empty vector while yours
returns 0 0

--
Raul
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to