Yes, what I said is it seems like a misnomer. Functional J has
variables, but they are handled by the interpreter? Still they are never
changed? This could create a performance problem if you do a lot of
small changes to big data structures? It is essential to handle this
efficiently? Still J does not have lazy execution? The functional
transformations Amend does are immediately executed? Maybe J sometimes
only creates new pointers to old static data structures? /Erling
On 2014-07-08 00:21, Jose Mario Quintana wrote:
What variable? Tacit programming does not refer to any arguments
explicitly; or, are you saying that “amend” is a misnomer (if so, that is
not my domain)?
On Mon, Jul 7, 2014 at 6:07 PM, Erling Hellenäs <[email protected]>
wrote:
A principle of functional programming is you never modify a variable? What
Amend does is create a new variable from other existing variables? Nothing
is amended? /Erling
On 2014-07-07 23:50, Jose Mario Quintana wrote:
Erling wrote:
"
It's obviously not possible to do any amendments in tacit code? It is also
less elegant to pass these three parameters in the two arguments in tacit
code?
"
Well, Raul and I showed general verbs to perform amendments tacitly. Once
I was as puzzled as you are (were?) but I found enlightenment; maybe you
can find it as well:
http://www.jsoftware.com/pipermail/general/2000-September/004192.html
On Mon, Jul 7, 2014 at 1:53 PM, Erling Hellenäs <[email protected]
wrote:
It's obviously not possible to do any amendments in tacit code? It is
also
less elegant to pass these three parameters in the two arguments in tacit
code? Any opinions about the use of From to do the same thing?
NB. x and y are arrays of the same rank
NB. q is a boolean, also of this rank
NB. The expression merges x and y.
NB. Where q is TRUE it picks from y, otherwise x
NB. q {"0 1 x,"0 y
If q is a vector and if we actually have a variable z of rank (+/q),}.$y
we can easily create x from q#^:_1 [ z ? No use for any indexes?
/Erling
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm