> From: david alis
> 
> Forming tacit expressions with 1 : 0 offers two advantages.
> Firstly, with 1 : 0 it's easy to modify a tacit program.
> Secondly, tacit elements can be analysed to see that they
> behave as expected. In this case  +&.>/ is faulty.
> 

I'm always interested in exploring better ways of doing things but so far I'm 
not convinced that this methodology offers much benefit to me. Perhaps the 
benefits of the technique depend to some extent on the development 
environment/methodology/habits of the developer?

To put my comments in perspective:

I do most of my development using with a J session (.ijx) and one or more 
separate script windows (.ijs) open.

If I want to build up the components of a tacit verb, I can do that in the 
script window as I tried to illustrate in a previous post:

NB.==== script window ======

NB.*raul v sum numbers by unique key
 a=. [: ~. [       NB. nub of left
 b=. +&.>/
 res=. a ,. b/.    NB. put it together
raul=: res/ f.     NB. apply adverb /

NB.==========================

If I make a change to the script, I press Ctrl+w and the script is reloaded in 
my session and the new version of raul is defined in the session. I'm not sure 
how wrapping the above in 1 : 0 would help make it easier to modify the tacit 
verb?

However mostly I find that when I'm developing a tacit expression, I do this by 
experimenting directly in the session, progressively building up the components 
of the tacit verb to get the result I want. This doesn't lead to especially 
readable code, but seems to "work best" for me. 

In my opinion the biggest advantage of the general approach that you suggest is 
the ability to document the components of the tacit verb. I'd prefer the above 
to the strategy Kip described because this way I don't end up with a whole lot 
of myverbdef adverbs in my locale. 
If I want to see what the verb raul does I type in the session:
   namedoc 'raul'
raul (v) sum numbers by unique key

The namedoc verb is described on the wiki 
"http://www.jsoftware.com/jwiki/OlegKobchenko/Namedoc"; and I have it loaded in 
my startup script.

If I want to see the documented definition of the tacit verb I'd type in the 
session: 
  edit 'raul'
... which will open up a script window at the definition of myverb. 

I realise this last technique isn't available to console users though!

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

Reply via email to