« first day (1773 days earlier)      last day (867 days later) » 

12:45 AM
@FawnLocke As you note, the ecosystem of Dyalog is relatively very large, and that is not necessarily bound to change. BQN may or may not develop a big ecosystem.
More importantly, its never clear in the moment that a new design is not simply making a a whole bunch of new mistakes as it seeks to correct all the old mistakes. I think J was supposed to fix all of the mistakes of APL, like having a special character set.
 
 
3 hours later…
3:21 AM
I guess we'll see. I appreciate the response
 
 
2 hours later…
5:45 AM
how to filter?
Ex:
0 1 0 0 1
1 0 0 1 1
1 0 1 0 1
0 1 0 1 0
0 1 0 1 0
^ and 1 and the other argument
outputs
1 0 0 1 1
1 0 1 0 1
 
you should be more specific by what you mean by "filter"
do you have a predicate function and you want to return all elements that pass the predicate?
 
i want a dfn, taking ⍺ as a bool matrix and ⍵ as a bool value
that filters ⍺ outputting only the rows which start with ⍵
 
6:10 AM
Advent of Code 2021?
I just used traditional array index for part 2
followed by filter. all in a while loop with tradfns
both this one and yesterday's part2 discourages array oriented thinking. I didn't even choose APL for yesterday's part2 (and use Lisp instead).
 
 
1 hour later…
7:45 AM
good day
 
8:16 AM
I must say I have a pretty tasty part 2 for today's AoC
I'll publish my solutions so far later today
 
8:47 AM
Did you manage to do it without power or recur?
 
i didnt even manage to do the part 2
 
@xpqz No not that tasty
Is that possible? I could see someone fudging a scan but the dependency seems unavoidable
 
Not sure it’s possible
 
The thing I like is I have a scrub operator, so I can use ≤_s for one and >_s for the other
 
Ha. I did the same!
 
8:56 AM
 
@xpqz we are also neck-and-neck in rak's leaderboard... suspicious...
 
@RikedyP Ooh, interesting, I'll try to rewrite my solution to use an operator. Haven't tried to write an operator before…
 
@klao It's literally just once you spot that you'd have identical code but with the comparitor switched, swap the ≤ for ⍺⍺ and your dfn becomes a dop like magic
 
@RikedyP Yeah, I passed a "bool" parameter to my scrub on the left and xored the result of the comparison with it. So, I don't have duplicated code, but the operator is way nicer!
 
 
1 hour later…
you haven't added 'fn'
 
Disgraceful. Try now.
On reflection, probably had been neater with instead of .
 
11:01 AM
always happy to see a differential operator in code :)
 
11:15 AM
Spot the mathematician...
 
@xpqz nice
thanks
neat solution
 
 
1 hour later…
12:45 PM
@PyGamer0 m⌿⍨1=⊣/m
 
12:58 PM
@Adám how does it work?
 
1:21 PM
⊣/m gets the leftmost column of m. 1= gives you a boolean vector, 1 for rows you want to keep, 0 to discard. m⌿⍨ uses that to filter the rows of m
 
 
3 hours later…
4:13 PM
@milia judging by it's usual usage, it's probably a bit more like gradient operator
 

« first day (1773 days earlier)      last day (867 days later) »