I was confused for a moment when you said "The linear display of ({:}
}:) is wrong."

But then I saw that you meant the linear display of ({:} }) in the
error message for ({:} })t

It can also be instructive to try that expression:

   9!:3(5)

   ({:}}:)
{:}  }:

In other words, in the current version of J, at least, when there's no
opening {{ a }} pair is not treated as a delimiter.

That's arguably for the best. (Though for old J hands, it also
suggests that smiley/frowny delimiters -- in other words (: ): --
might have been more comfortable for us.)

Thanks,

-- 
Raul

On Fri, Dec 10, 2021 at 10:51 AM Henry Rich <[email protected]> wrote:
>
> What you have is
>
>   ({:} }:)t
>
> t {:} }: t
>
> [This is u}]
>
> t (t {: }: t)} }: t
>
>
> The linear display of ({:} }:) is wrong.
>
>  From your NuVoc ref it appears you want to use monad u}, but you are
> using the dyad here.
>
> Henry Rich
>
>
> On 12/10/2021 10:24 AM, R.E. Boss wrote:
> > I'm trying to solve the AdventOfCode puzzles, but at least half of my time 
> > I spend on troubles with J.
> > Mostly I make mistakes, because the rules of J are less intuitive then I 
> > presumed, but there is also inexplicable behavior, so in the end, J remains 
> > a black box for me.
> >
> >    t
> > 3  1  4  1  2  1  1  8  8  3  6  7  3  3  4  3  6  4  2  1  8  2  7  7
> > _6 _8 _5 _8 _7 _8 _8 _1 _1 _6 _3 _2 _6 _6 _5 _6 _3 _5 _7 _8 _1 _7 _2 _2
> >   0  0  0  0  0  0  0  1  1  0  1  1  0  0  0  0  1  0  0  0  1  0  1  1
> >
> >     ({:} }:)t
> > |domain error
> > |       ({:}}:)t
> >
> > obviously }} is interpreted as part of a direct definition, red in JQT, 
> > despite my blank.
> >
> >    (}:}~ {:) t
> > |domain error
> > |       (}:}~{:)t
> >
> > black box in optima forma.
> >
> > Fortunately, as NUVOC mentions, } is a replacement of ( {"0 1&.|: ).
> > But it cost me too much time, reason to timebox my efforts for AOC.
> >
> >
> > R.E. Boss
> > ----------------------------------------------------------------------
> > For information about J forums see http://www.jsoftware.com/forums.htm
>
>
> --
> This email has been checked for viruses by AVG.
> https://www.avg.com
>
> ----------------------------------------------------------------------
> 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