The variables u, v, m, n  (and also x, and maybe y too)
are special in that they are evaluated immediately rather
than being put onto the stack by name.  You can see why:
since they are implicitly redefined when an explicit
definition starts, a hash would result if they were saved
by name (they would have a wildly different value when
they were executed from what they had when they were
defined).

I do not have the time to run the experiments to prove
that what I just wrote is precisely correct, but it's
close.  The argument variables are special.

In your example, use a different name, or move the
assignment to n before the assigment to avg.

Henry Rich



> -----Original Message-----
> From: [EMAIL PROTECTED] 
> [mailto:[EMAIL PROTECTED] On Behalf Of Brian Schott
> Sent: Saturday, November 18, 2006 12:29 PM
> To: General forum
> Subject: [Jgeneral] problem with verb 'n' in load
> 
>       Consider the simple file attached below and the
> error it throws. The error is not thrown if the verb name n
> is changed to nn . And the error is not thrown if the lines
> are entered directly into jconsole.
> 
>    load'/Users/brian/j601/user/cluster/testload.ijs'
> |value error: n
> |   avg=:sum%    n
> |[-3] /Users/brian/j601/user/cluster/testload.ijs
>    (9!:12;9!:14)''
> +-+---------------------+
> |5|j601/2006-09-04/09:20|
> +-+---------------------+
> 
> ************simple file listed below***************
> NB. testload.ijs
> NB. 11/18/6
> 
> avg =: sum%n
> sum =: +/
> n =: #
> 
> (B=) <----------my "sig"
> 
> Brian Schott
> Atlanta, GA, USA
> schott DOT bee are eye eh en AT gee em ae eye el DOT com
> http://schott.selfip.net/~brian/
> ----------------------------------------------------------------------
> 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