Remember that operators bind stronger than functions, so the first thing that happens is that ⍨ binds 2 to become a function. Now the three rightmost functions are ⍳ * 2⍨ which becomes a function, and then we have the functions +/ (⍳*2⍨)
@xpqz The RIDE User Guide is something I want to attack in the not too distant future (along with parts of the macOS User Guide). By default there's no security with RIDE, but at the other end of the scale you can use certificates at both ends to limit access .. and there's various other stages between.
OK, so there's a built-in vector called ⎕AVU (don't worry about what it is for). You can type ⎕ with APL-key+L. How many elements in `⎕AVU are greater than 100?
Very good. What I wanted to demonstrate here is the APL way of using Boolean values for computations and other processing.
@KrzysztofSzewczyk The First one is very simple. It uses the "each" operator which takes a single function and applies it separately to each element of the argument(s).
@KrzysztofSzewczyk Let's teach you "filtering". Given a Boolean vector B and a vector of values V, B/V removes all the elements of V corresponding to 0s and leaves those corresponding to 1s.
@KrzysztofSzewczyk It's nice to see how quickly you're picking up the language used when talking about APL ! "evil" "beautiful", "dog's dinner" .. and you know when you've got a bit of code right because it just looks right !
@KrzysztofSzewczyk Let's teach you "filtering". Given a Boolean vector B and a vector of values V, B/V removes all the elements of V corresponding to 0s and leaves those corresponding to 1s.
@xpqz Can you set the env var APLCORENAME=$HOME/myaplcore. Then try again. It might also be worth taking a look in /cores - that is if you have core file generation enabled. If you get a core file or an aplcore, we can take a look. Sorry .. been rather busy today - did you install the new 18.0 for macOS ?
@KrzysztofSzewczyk - If you're learning APL from scratch, talk to @Adám (who is very helpful), and look into getting copies of Mastering Dyalog APL by Bernard Legrand, and possibly APL: An Interactive Approach by Leonard Gilman and Handbook of APL Programming by Clark Wiedmann. The Gilman and Wiedmann books focus on older versions of APL, but are still valid for basic language information (they also include information about using systems, which is definitely outdated).
The main idea is just to be consistent about never putting dividers between elements, instead of having them in general but just using spaces for all-number or all-character arrays.
Oh, there are big versions of floor/ceiling. ⎡ 12 15 18 ⎦ looks pretty good.
@dzaima 2 is a little too high, but I think 1 is much too low. I'll see if I can figure out where to put ligatures as they're definitely better in this case.
Another BQN thing is a new keyboard layout I'm working on:
Yeah, this layout should be easier to type with because I vacated a lot of the middle keys.
I find the middle keys hard to remember too, so 9 is much better than 7 for me.
‿ on the space bar; that isn't shown.
Definitely adding ˝; ↙↖ are characters I might use for load/store in the compiler, and ⍎⍕ are just there for dzaima/BQN but I'm sure I'll probably have some primitives for that sort of functionality.
Wonder if I should swap ¨⚇ and ˘⎉? Then "one curve, two dots" would be a mnemonic.
I'm making BQN's monadic = be Rank (i.e. returns the rank of the argument, or 0 if it's not an array). Obvious choice of symbol, and something that's more basic than the shape should really have its own primitive.