I have been trying unsuccessfully to setup the keymap on a console to program in APL. My machine is remote, hence I do not have Xorg installed.
How can I setup my keymap/charset to correctly produce APL symbols?
hah, i like the way you wrote the feeds avatar with unicode :P that would be cool. but making it into the style of the current icon would take a bit of effort
ah, i see. well if y'all do ever want a custom feed name/avatar feel free to ping me :p unfortunately a mod has to do it AFAIK; ROs can't just set it up for any room sadly. i just brought it up because i saw the SO feed post and noticed it was default. nothing wrong with that ofc.
@Adám ⍞← does NOT mean "send to stderr". It happens to do that in current Dyalog APL, but I consider this to be one of the most bizarre decisions in the implementation and it may well come to an end when we re-implement the guts of the I/O handling in order to wrap up the #! scripting project by adding RIDE support, planned for v19.0.
@rak1507 Yes and no. Yes, officially. No, because in all likelihood, real-world usage will uncover important components that are glaringly missing, and maybe even things that have been done wrong in the initial attempt.
@rak1507 In 18.1, scripting is missing at least one key feature, which is debug-ability via RIDE. This is the piece that requires a rewrite of some core I/O functionality as we need to teach the interpreter that "debug input" and "user input" may come from different sources. We need to add a central switching station.
@MortenKromberg On the other hand, I think plenty of users will be happy for the script execution to stop altogether on error, rather than be dropped into a tracer.
Indeed, so the scripting support in 18.1 is already valuable. However, in more complex scenarios, the ability to attach a debugger will be even more valuable.
What might (I've not tested it) be sorely missing in 18.1 is the ability to prompt the user for input, and get what they wrote back in a safe manner. Also, printing something (please wait...) and then erasing it again.
Without risking that part (or all) of the prompt is included in the input, nor that any of the input is lost.
Try e.g. ⍞←'prompt: ' ⋄ 8↓⍞ and then backspace over the prompt before you start typing.
You might come up with something like {⍞←⍵ ⋄ i←⍞ ⋄ i↓⍨+/∧\=⌿↑⍵ i}'prompt: ' but even this will fail if the user backspaces over the prompt and then retypes the same characters as the prompt had in those positions.
We'll also be looking at whether a completely new input mechanism is required, in addition to QuoteQuad, which has, ah, interesting features which were very useful in the day of the teletype.
Speaking of typing glyphs, has anyone managed to get a semi-decent experience writing APL in VS Code? The option key is used by VS Code for certain chords meaning that some glyphs (to my knowledge) seem untypeable. Annoyingly including ←.
(on a Mac....)
May have to make a completely new keyboard layout using the fn key instead of option (fn key isn't used for anything really on a mac).
@xpqz Can the function key be used in keybindings? I remember having difficulties swapping the Ctrl and Fn keys on a Lenovo because it's special in some way
@Adám Hi Adam, I did install Dyalog in MacOs and have no problem using the glyphs there after following the instructions.
Now, I would really like to use Dyalog on an Ubuntu AWS instance through Blink on my iPad to gain a bit of remote flexibility. That is where my current challenge rests now.
But for this learning stage, I will probably then stick to my Mac.
My plan is to learn APL and use it in the context of my research (mathematical physics), will probably remain close to this chat in the meantime.
@SantiagoNuñez-Corrales That shouldn't be a problem to arrange. The dyalog executable can serve RIDE which any browser with access to the exposed port can then access.
@SantiagoNuñez-Corrales Where are you up to with your learning? Do you need any pointers to materials?
somewhat related: do you perhaps have reading or watching recommendations for thinking in vectors (for lack of better words)
I think I am looking for input that helps me with examples so I can build an intuition for "seeing" a vector representation of a solution when I am tackling a problem
ah. alright. basically, i have (1∘↓+\⍣¯1) that takes an array and returns its forward difference array; i want to apply that N times (N is the length of the list) and have all intermediate results
before considering golfing (1∘↓+\⍣¯1) - what would be the most idiomatic way of going about something like this?
(also, i'm not sure if porting my jelly answer is the best way to solve this challenge anyway lol. wanna give it a shot though)
i was writing 2-/ 1 2 3 4 5 so that didn't quite help with my understanding of it, but looking at the tryapl built-in guide for / and how it was spaced made me realize how that worked
@Bubbler yes :c lmao
er, why does (2∘-/) not work? (says "this function does not take a left argument") - am I misunderstanding how composing / partial-functions work?
X f¨ Y does vectorize instead of each on either side. what's the best way to make it only loop over X or only loop over Y? I could work around it with a different structure but it'd probably be considerably longer and I'm wondering if there's a better way to do it