Hi Harvey, the left argument to ‘from’ should be a single noun.  In your 
expression:
        (2*j) (1+2*j) { ‘mevema'
You have
        Noun1 Noun2 { Noun3

Which actually gives you s syntax error (N N V N)

You need:
        Noun1 { Noun2

Since the left arg you want is 0 1, try this:
        ((2*j), (1+2*j)) { ‘mevema'
me

Or perhaps better:
        (0 1+2*j) { 'mevema'
me

(0 1+2*j) evaluates to 0 1 as a single Noun.

Best, Rob

> On 13 Apr 2021, at 6:14 pm, HH PackRat <[email protected]> wrote:
> 
> Hello, all!
> 
> I'm stumped and need to know why the following "from" problem occurs
> and how to do what I'd like to do:
> 
> No problem when numeric values are used:
>   val=. 0 1 { 'mevema'
> me
>   val=. 2 3 { 'mevema'
> ve
> 
> Problem when formulas are used instead of numeric values:
>   j=. 0   [or 1 or 2]
>   val=. (2*j) (1+2*j) { 'mevema'
> |syntax error
> |   val=.    (2*j)(1+(2*j)){'mevema'
> 
> Why does "from" work with numeric values but not with formulaic
> versions of those same values for use inside a "for_j" loop to handle
> multiple cases?
> 
> What I'm trying to do is to grab 2 letters at a time in sequence
> through the 6-character combined planetary abbreviations for 3
> planets.  Is there another way?  (Explicit code only, please, if you
> give any examples.)
> 
> I just don't understand why one version works and the other doesn't.
> Any help appreciated!
> 
> Harvey
> ----------------------------------------------------------------------
> For information about J forums see http://www.jsoftware.com/forums.htm

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

Reply via email to