Hello Stephen;

I am sure someone has said this earler, but just in case:

  |.</.*/~i.10

seems to give you what you want.

Steven Taylor wrote:
Hi,

I'm new to J.  I like what I see so far.

Here is simplified version of the problem I'm trying to solve.
N =: i.10
M =: |. i.10
< \ (|. N) * M

│81│81 64│81 64 49│81 64 49 36│...│81 64 49 36 25 16 9 4 1 0│

But what I want is actually the reverse of the cumulative window.  Not the
reverse of the entire list N -- only the reverse of N after N is broken into
a segment.

The result I'm trying to get:
|9 * 9|9 * 8 8 * 9|9 * 7 8 * 8 7 * 9|9 * 6 8 * 7 7 * 8 6 * 9|... etc
Which is |81|72 72|63 64 63|54 56 56 54|... etc

Thanks,
-Steven

P.S. Sorry about the duplicate email.  I hit ctrl+enter in outlook when I
meant to do this in a different program.

Internal Virus Database is out-of-date.
Checked by AVG. Version: 7.5.526 / Virus Database: 270.8.0/1722 - Release Date: 13/10/2008
07:50
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm


--
------------------------------------------------------------------------
|\/| Randy A MacDonald       | APL: If you can say it, it's done.. (ram)
|/\| ramacd <at> nbnet.nb.ca |
|\ |                         | The only real problem with APL is that
BSc(Math) UNBF'83            | it is "still ahead of its time."
Sapere Aude                  |     - Morten Kromberg
Natural Born APL'er          |
-----------------------------------------------------(INTP)----{ gnat }-



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

Reply via email to