Hi Raul,

Indeed, I was confused about what was an atom and what is not.

Thank you for this roadmap. After pondering your answer, I think I'd better
go back to re-reading the documentation.

Thanks again for the help!

Raoul

Le jeu. 20 févr. 2020 à 18:38, Raul Miller <rauldmil...@gmail.com> a écrit :

> First off, I don't think you understand J syntax.
>
> This is, syntactically, a single word within J:
> 1 2 3 4 5
>
> And, similarly, this is (syntactically) a single word within J:
> 'this is a test'
>
> But, also, this is a syntax error in J:
> 't' 'e' 's' 't'
>
> But just because that's a syntax error doesn't mean that 'test' is invalid
> in J.
>
> ....
>
> So one of the things we're going to have to work through will be these
> issues of understanding.
>
> ...
>
> Anyways... unanswered questions:
>
> (1) When a key from x appears several times within y, how is that
> reflected in the result? Why?
> (2) When a key from x is missing from y, how is that reflected in the
> result? Why?
> (3) What constraints exist on keys from x (can a key be a sequence?
> What are the rules for unboxing keys from x before they are looked for
> in y?)?
> (4) What constraints exist on values from y? (Obviously, they must
> conform or the result cannot be assembled. But under what rules are
> they organized?)
>
> And, what -- specifically -- is the rule for associating a key within
> y with the corresponding value within y? (This is probably obvious,
> but it's worth stating because we're tripping over conflicts between
> unstated assumptions.)
>
> Thanks,
>
> --
> Raul
>
> On Thu, Feb 20, 2020 at 3:00 AM Raoul Schorer <raoul.scho...@gmail.com>
> wrote:
> >
> > Raul,
> >
> > I realise that my questions are somewhat awkward and I'm doing things
> > that are way too complicated for me, but that's what I like about them
> > so sorry if I was unclear.
> >
> > The requirement is that I would like to substitute members of x with
> > those of y in a strict fashion, where x may be of any shape or type.
> >
> >   * The simplest case, as you stated: 1 2 (1&{::@] {~ 0&{::@] i. [) (2
> >     1;4 9)
> >   * But x may be boxed and y elements of different types: (1;2) (] {~
> >     0&{::@] >:@i.>@[) (2 1;'a';9)
> >   * Also, the substitution being strict, it should respect syntactic
> >     rules: 1 2 find (2 1;'';9) NB. should fail, as 9 '' yields a syntax
> >     error
> >
> > I hope I am making more sense?
> >
> >  > if that's doing what I think it's doing, it would be better handled
> > by omitting the associated keys from the data structure.
> > Can you explain a bit more of what you mean by that?
> >
> > Thank you very much for taking the time to help me!
> > Raoul
> > ----------------------------------------------------------------------
> > For information about J forums see http://www.jsoftware.com/forums.htm
> ----------------------------------------------------------------------
> 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