« first day (2118 days earlier)
← previous day
next day →
last day (553 days later) »
Adám
8:51 AM
@AidenChow
⊂{⍺/⍨⍵=|⍺-⍳≢⍺}¨⍳∘≢
with
⎕IO←0
and input/output adjusted by 1 (
allowed
).
razetime.github.io/APLgolf/?h=AwA&c=q37Uu/VRx4zqR727oh/…
3 hours later…
Adám
11:59 AM
@AidenChow Alternative approach:
{/∘⍵¨i=⊂|⍵-i←⍳≢⍵}
(again with
⎕IO←0
)
1 hour later…
rak1507
1:01 PM
if the order of the result doesn't matter why not use dyadic ⌸?
Adám
Yeah, I didn't quite understand. If the order doesn't matter, then the result is rather meaningless.
rak1507
btw ⍳∘≢ can be ⍳⍨ as it is guaranteed unique
Adám
I missed that point.
rak1507
⊢⊢∘⊂⌸⍨⍥|⊢-⍳⍨
is the shortest I have using that and the order not mattering
Adám
Why
⍥
instead of
∘
?
rak1507
1:07 PM
spoiled for choice :)
Adám
I'd also go for
⊂⍤⊢
over
⊢∘⊂
but that's a style.
rak1507
yeah ⊂⍤⊢ is probably clearer
Adám
⍳⍨⍛-⊢∘⊂⌸⍥|⊢
in 19.0
rak1507
nice
Adám
⍳⍨⍛-⍛(⊢∘⊂⌸⍥|)
if you don't like trains :-)
10 hours later…
Aiden Chow
11:05 PM
@Adám wtf how do these work
like bruh what am i even looking at
@rak1507 broooooo wat ?????????
this is some wizardry right here im looking at
« first day (2118 days earlier)
← previous day
next day →
last day (553 days later) »
all rooms
Transcript for
Nov
12
Nov '22
13
Nov
14
The APL Orchard
apl.chat
― Learn, teach, ask, code, golf, & discuss usage. See
...
2
apl
array-manipulation
j
tips
join this room
about this room
00:00
06:00
12:00
18:00
all times are UTC
site design / logo © 2024 Stack Exchange Inc;
legal
mobile