>> Even the classic example of a fork (+/÷≡) is harder to read than its
>> functional version {(+/⍵)÷≡⍵} and it goes downhill from there with longer
>> trains. But maybe it's just me being unfamiliar with the syntax.
>
>
> Did you intend to use ⍴ instead of ≡ there? I can't see how {(+/⍵)÷≡⍵} could
> ever be useful?

I guess Tobia meant ≢. Monadic ≢ is Tally, which gives you the length
of an array along the first axis (in NARS2000 and Dyalog version 14
and probably others).

Incidentally, if you're taking the length along the first axis, you
should probably reduce along the first axis too:

      +⌿ ÷ ≢
      {(+⌿⍵)÷≢⍵}

This will give you a useful result on matrices and higher-ranked arrays.

Jay.

Reply via email to