|
From: | Juergen Sauermann |
Subject: | [Bug-apl] ⊢[X] |
Date: | Mon, 27 Aug 2018 18:27:00 +0200 |
User-agent: | Mozilla/5.0 (X11; Linux i686; rv:52.0) Gecko/20100101 Thunderbird/52.8.0 |
Hi, I have added a new primitive function variant: ⊢ with axis. ⊢ with axis selects, according to its axis argument, its left argument, or its right argument, or a mix of items from both arguments: A←2 3⍴'abcdef' ⍝ left value B←2 3⍴⍳6 ⍝ right value X←2 3⍴0 1 0 1 0 1 ⍝ left/right selector A ⊢ [0] B abc def A ⊢[1] B 1 2 3 4 5 6 A ⊢[X] B a 2 c 4 e 6 A ⊢[X] '*' a*c *e* '*' ⊢[X] B * 2 * 4 * 6 That way hard to read →() / Label: constructs for the selection of different values according to a condition can be avoided. SVN 1071. /// Jürgen |
signature.asc
Description: OpenPGP digital signature
[Prev in Thread] | Current Thread | [Next in Thread] |