I wrote:
I've coded all this up at

   http://www.jsoftware.com/svn/DanBron/trunk/environment/fqn.ijs

Whoops, just realized that code depends on the name reduce_prefix . Remember my thread a couple of months ago, entitled "I know a shortcut"?

   http://www.jsoftware.com/pipermail/programming/2006-December/004568.html

Well, I never found the beautiful solution I was looking for (so I left my production code slow but correct). But, in retrospect, I realized the proof-of-concept challenge I posted, "reduce prefix", actually has its uses. So I kept it around. You can find it here:

   http://www.jsoftware.com/svn/DanBron/trunk/environment/reduce_prefix.ijs

Thinking back, R.E.Boss posted a solution to my challenge,

   http://www.jsoftware.com/pipermail/programming/2006-December/004579.html

which is probably superior. I'm embarrassed to admit that I never read through it. At the very least, it has no explicit loops, unlike mine.

In any case, for FQN.ijs to work, you'll need to define reduce_prefix . You can do this by having the script require 'reduce_prefix.ijs' or by putting the definition (either Boss' or mine) in FQN.ijs itself.

-Dan

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

Reply via email to