stdlib: standard library | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
assert value is true assertion failure if 0 e. y e.g. 'invalid age' assert 0 <: age binds argument to a monadic verb binds monadic verb to an argument creating a new verb that ignores its argument. e.g. fini=: wdinfo bind 'finished...' box argument if open boxxopen - box argument if open and # is not zero e.g. if script=: 0!:0 @ boxopen, then either script 'work.ijs' or script <'work.ijs' use cutopen to allow multiple arguments. clear all names in locale returns any names not erased example: clear 'myloc' cut argument if open this allows an open argument to be given where a boxed list is required. most common situations are handled. it is similar to boxopen, except allowing multiple arguments in the character string. x is optional delimiters, default LF if in y, else blank y is boxed or an open character array. if y is boxed it is returned unchanged, otherwise: if y has rank 2 or more, the boxed major cells are returned if y has rank 0 or 1, it is cut on delimiters in given in x, or if x not given, LF if in y else blank. Empty items are deleted. e.g. if script=: 0!:0 @ cutopen, then script 'work.ijs util.ijs' boolean expand form: boolean expand data list data formatted in columns syntax: {width} list data accepts data as one of: boxed list character vector, delimited by CR, LF or CRLF; or by ' ' character matrix formats in given width, default screenwidth selective namelist Form: [mp] nl sel sel: one or more integer name classes, or a name list. if empty use: 0 1 2 3. mp: optional matching pattern. If mp contains '*', list names containing mp, otherwise list names starting mp. If mp contains '~', list names that do not match. e.g. 'f' nl 3 - list verbs that begin with 'f' '*com nl '' - list names containing 'com' notes in script Monadic form: This enables multi line comments without repeated NB. and requires a right parenthesis in the first column of a line to close. The right argument may be empty, numeric, text, or any noun. Reads and displays the comment text but always returns an empty character string so the comment is not duplicated on screen. The right argument can number or describe the notes, e.g. Note 1 Note 2.2 or Note 'The special case' etc. Dyadic form This permits a single consist form of comment for any lines which are not tacit definitions. The left argument must be a noun. The function code displays the right argument and returns the left argument. examples: Note 1 ... note text ) (2 + 3)=(3 + 2) Note 'addition is commutative' split head from tail examples: split 'abcde' 2 split 'abcde' function table table - function table (adverb) e.g. 1 2 3 * table 10 11 12 13 +. table i.13 convert text to upper case earlier defs can fail on unicode data: 'l u'=. (a.i.'aA') +each <i.26 tolower=: a.&i. { ((l{a.) u} a.)"_ toupper=: a.&i. { ((u{a.) l} a.)"_ convert text to unicode code point This is 7-bit ascii (if possible) or utf16 (compare uucp) inverse is utf8 unicode code point count counts number of unicode code points (glyphs) in a string. A unicode character has one code point, even though it may have several bytes in its representation. convert string to utf8 inverse of ucp convert text to unicode code point This is always utf16 (compare ucp)
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
>> << Ndx Usr Pri JfC LJ Phr Dic Rel Voc !: wd Help User |