@sloorush Yes, we just need a little time to cut and trim the single long recording into individual talks. After that, you'll find them on Dyalog TV and on YouTube.
So ,⍤0 concatenates each pair of scalar-from-Xv with scalar-from-Yv, keeping the outer (vector, rank 1) shape, but since the major cells (which were scalars, rank 0) are now vectors (rank 1), the entire shape becomes a matrix with 2 columns.
Here the , only ever sees a scalar on the left and a scalar on the right, because ⍤0 restricts it to see arguments of rank 0 (scalars). The ⍤ then collects these results together to form one array.
IIUC, Phase 2 is intended to test your broader programming skills with APL, not just how well you grok the primitives. Forcing dfns/tradfns is perhaps a way of encouraging us to add comments, error handling, and all that jazz.
I guess that kind of makes sense, but 2:1:1 is basically impossible to comment without just restating exactly what the code does, which is probably easier to understand by just reading the code than the comment
Yeah, the happy-path solution is just a few characters, but what happens with unexpected input? Maybe you think that's not particularly relevant, in which case you could talk to the judges with a comment saying something to that effect.
In my opinion, one of the interesting things about APL is that the primitives can take on salient domain-specific meaning when you restrict their use to a particular problem. Adding a comment that explicates something like that might be reasonable.
Aw... Selective Assignment doesn't support Mix and Split: (m/↓⍉↑A B C)←a b c. Trying to bulk-update records in an inverted table where columns are stored in variables, e.g. A, B, and C above.
First dumb-headed idea: ∆←my table and A B C←1 2 3 are my column indices, so then where we would previously write (m/A)←blah, we can now write (m/A⌷∆)←blah`.
@B.Wilson That's pretty clever. Or even (m⌿∆[A B])← as then you can modify multiple columns at once. That said, be careful about modifying "cells" rather than entire records.
Well, it is deliberate, but a necessary cost for automated sanity checks. Btw, you can easily circumvent the restriction by wrapping your tacit functions (and don't worry; we'll not count that against you):
@Adám That needs to be ((⊂m)/¨∆[A B])←, right? Meaning that your ∆ is actually a vector of vectors? Also, are you using first-axis Replicate just because first-axis Rulz™ or is there a deeper reason?
As far as I can tell, the only way to get at the full error message we usually see in the session is with the former. Is that right? Looks like Message doesn't contain the info about problematic source line and location.
InternalLocation is fun :D Feel like I'm looking at classified information here.
@Adám Ah, Dzaima APL. Neat. I actually have Dzaima installed on my laptop as well. Though, I have a Pinephone laying around, which might just need to get Dyalogified.
@LdBeth That's probably pretty good in a pinch. There's even a J keyboard installed with the Android app, right?
Is there a problem with "excessive" comments in phase 2 solutions? I write my solutions in a custom half-implementation half-tool of thought dialect which I then port over to Dyalog, but for ease of maintaining I've been leaving both the original code as well as extensive documentation comments, which I guess are mostly useless for judging, but I'd guess they won't harm either? Just checking in case I make my life harder for no reason :)
I don't speak for Dyalog, but if you look at the source for some of the functions in the dfns workspace you can see the level of documentation some masters of the art include with their code.
I'm looking for an APL interpreter running native on Apple silicon, namely MacBook Pro, M1 Max, 64G, Mac OS 13.2.1. I only found Dyalog (working fine) but Rosetta mediated. Any idea, anyone ?
(didn't try to build GNU APL yet)