I have run into this problem, defining multiple lines and failing or
entering them awkwardly where I really do not want to do it all in the
editor- NOW I know how to handle this. It makes a difference i my
frustration level
Thanks to you all ,
Don Kelly
iter=: (, 1 , +@|.) @: (,~ 0j_1 ,~ 0j_1*|.)
hilbert=: {{0j1+(%{:) +/\0,iter ^: y ''}}
require 'plot'
plot hilbert 5
On 2022-07-31 12:34 p.m., Henry Rich wrote:
He must have pasted the two lines for iter and hilbert lines together.
Then he loaded plot and ran hilbert, with iter undefined.
Never mind this example: beginners encounter this often, and it's very
nonintuitive, because you can see the lines in the term window with no
indication that some of them were not executed. I saw it a lot in my
classes.
I don't see any downside to executing multiple lines pasted into the
last line.
Henry Rich
On 7/31/2022 2:14 PM, chris burke wrote:
Note that the error occurred in hilbert. So the OP had run that line
correctly. It was not that he had pasted the multiple lines and
pressed Enter expecting them all to run.
On Sun, Jul 31, 2022 at 8:50 AM Henry Rich <henryhr...@gmail.com> wrote:
I agree with you. That would be a change and might discommode some
old-time users, but I bet few would notice.
We could say, pasting above the last line merely edits the log, while
pasting into the last line executes all sentences ended by LF. That is
a very small change from the current behavior.
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm