took me a while to find it, as it is a mistake I often make:
nn =: ('a' ('t' adv) ]) : ([ 't' adv ])
----- Original Message -----
From: Brian Schott <[email protected]>
To: Programming forum <[email protected]>
Cc:
Sent: Friday, October 3, 2014 1:56 PM
Subject: [Jprogramming] dyadic adverb for ambivalent verb
I have defined an adverb `adv` and a verb `nn`. I want the latter to
produce either literally a noun or an executable phrase. The adverb `adv`
works for the dyadic case, but not for the monadic case. I want the
ambivalent verb *form*, but am willing to adjust other aspects of the
adverb and verb.
Thanks,
adv =: 1 : 0
:
x,' ',m,' ',":y
)
nn =: ('a' 't' adv ]) : [ 't' adv ]
'z' nn 4
z t 4
nn 4 NB. I want the result: a t y which is a t 4 in this case
a t 4 t 4
--
(B=)
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm