Henry Rich wrote:
|The loop could be replaced by
|table =. (<"0 i. #table) (<a:;0)} table

Thanks for all your help!

You suggested that the loop could be replaced by a "loopless"
single-line version.  Does your suggestion apply only to my posted
"simplified" version?  The "real" version's loop (now incorporating your
solution) looks more like this, where "cleanfield" is an explicit
definition for doing some cleanup work (for testing purposes,
"cleanfield" definition contents of something like  'xxx',y  works
fine):

for_j. (i. numrows) do.
  isbnfld=. <cleanfield >0{j_index{table   NB. get and modify ISBN cell
contents
  table=. isbnfld (<j_index,0)} table      NB. replace ISBN cell
contents in table
end.

Is this complication of including a called function still amenable in
some way to your single-line suggestion above?  It would sure be great
if it could.  Thanks!

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

Reply via email to