First=:(`i.)(`1:)(`:6) First ((`i.)(`1:))(`:6)
(4<])First (4 < ]) i. 1:
Date: Sat, 2 Nov 2013 12:06:56 -0700 (PDT) From: Pascal Jasmin<[email protected]> To:"[email protected]" <[email protected]> Subject: [Jprogramming] making a 'first' adverb tacit Message-ID: <[email protected]> Content-Type: text/plain; charset=iso-8859-1 I'm pleased that this is as elegant as it is already, but can the 2 adverbs be defined tacitly? first =: 1 : 'u i. 1:' retitem =: 1 : '] {~ u' ? ?(4<])first i.7 5 ? ?4< first i.7 5 Its nice that the adverb doesn't require a duplicate dyadic definition. ? ?4< first >:i.7 4 ? ?4< first retitem >:i.7 5
---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm
