[Jprogramming] Self-reference in an explicit definition
Raul Miller
rauldmiller at gmail.com
Tue Sep 4 13:19:11 UTC 2012
$: refers to the largest containing verb in the current sentence. Explicit
definitions contain sentences.
--
Raul
On Tuesday, September 4, 2012, Ian Clark <earthspotty at gmail.com> wrote:
> Let's define a verb: max which can be used either dyadically:
>
> 5 max 7
> 7
>
> or monadically:
>
> max 5 7
> 7
>
> Can somebody explain to me please
> (for the purpose of completing
> http://www.jsoftware.com/jwiki/Vocabulary/dollarco )
> why this works:
>
> max=: $:/ : >.
>
> but this doesn't:
>
> max=: 3 : 0
> $:/y
> :
> x>.y
> )
>
> The explicit version (which to me looks equivalent to the tacit one)
> does not work with a noun longer than 1 atom:
>
> max 7
> 7
> max 5 7
> |stack error: max
> | $:/y
> ----------------------------------------------------------------------
> For information about J forums see http://www.jsoftware.com/forums.htm
>
More information about the Programming
mailing list