Entering CTRL-D (0x04) in a script or from the keyboard causes J to exit immediately.

io.c:243

Henry Rich

On 10/28/2022 9:26 AM, Raul Miller wrote:
try=: {{
   0!:0 y
}}

trys=: {{
  'nchars ntries'=. 3 >. 2{.x
  s=. 0
  for.i.ntries do.
   try. try y{~nchars?#y
    s=. s+1
   catch. catcht. end.
  end.
  s%ntries
}}

3 1e5 trys a.

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

Reply via email to