Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
rak1507
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
11 ms
·
91.
▲
by
rak1507
4y ago
'However, to even begin to understand it you have to read an article from the original writer' - or just know APL? If you know APL, it's clear.
92.
▲
by
rak1507
4y ago
Challenge Accepted! Here is the core: using UDLR unlike the article snake←{d←9 11○0J1\*'DRUL'⍳⍺ ⋄ n←(⍴⍵)|(⊣/c)+-⍣(d≡p)⊢d⊣p←-⍨/c←(⍴⍵)⊤2↑⍒,⍵ ⋄ b←(1+⌈/,⍵)@(⊂n)⊢⍵ ⋄ ¯1=n⌷⍵:1-⍨@(⊂(?∘≢⊃⊣)⍸0=⍵)⊢b ⋄ 1-⍨@(0∘<)⊢b}
93.
▲
by
rak1507
4y ago
'There is a surprising lack of APL-derived languages that use words to name things' - This isn't really surprising when you consider the history of APL, and what it was designed for. Arguably you could say something like nump
94.
▲
by
rak1507
4y ago
That's partially the goal of https://aplwiki.com/wiki/APL_Campfire and https://www.arraycast.com/
95.
▲
by
rak1507
4y ago
What was the bug?
96.
▲
by
rak1507
4y ago
I used foldl1 (+) because that's the literal translation of +/. I used (fromIntegral.length) instead of genericLength because genericLength requires an import (as does liftM2 actually, so I should've used that). 'Not muc
97.
▲
by
rak1507
4y ago
The link you provided doesn't seem to work for me. I don't think it's a particularly useful metric anyway, as the actual code matters a lot, not just the semantics. Also, those examples were very simple ones, and APL has a lo
98.
▲
by
rak1507
4y ago
Wow, if you completely change the language to make it more verbose, it becomes more verbose! Incredible.
99.
▲
by
rak1507
4y ago
You don't type tokens. Maybe if your keyboard has a 'factorial' button that's better, but mine doesn't. (Also J is extremely useful in a variety of other ways that would be much more complicated to replicate in pyth
100.
▲
by
rak1507
4y ago
match ? definitive proof that verbosity introduces bugs ;) (also you can't deduce what ! means? it's literally the factorial symbol)
101.
▲
by
rak1507
4y ago
Array languages (APL/J/K/Q) all do this well, particularly kdb
102.
▲
by
rak1507
4y ago
'The APL version we were using had dynamic scoping. TIL that there are multiple variations of the same language with totally different semantics!' - your own code uses localisation within tradfns! Dfns just do that by default.
103.
▲
by
rak1507
4y ago
This might have been true a couple of years ago but it is totally untrue now. I'm not sure why you couldn't use the student version of Dyalog? Sounds like it would have been fine. There are also many more FOSS implementations of a
104.
▲
by
rak1507
5y ago
<pedantry> if the population is 90% green, the chance of getting 6 greens in a row is only about 53% (tends to 53% as size -> inf) </pedantry>
105.
▲
by
rak1507
5y ago
Yeah maybe, but in my opinion it's better than the alternative (having loads of operator precedence rules that can change subtly between languages and never really being sure of anything).
106.
▲
by
rak1507
5y ago
I think there's a compromise between being recognisable as a mathematical formula and removing operator precedence which is what APL and other array languages do. (a×1-t)+b×t is how you'd write it in APL, no operator precedence bu
107.
▲
by
rak1507
5y ago
lol do you actually think people care about providing the 'best quality software they can create' https://www.npmjs.com/package/is-even etc
108.
▲
by
rak1507
5y ago
Or people could just write it correctly in the first place! Controversial I know! Seems like people would rather half-ass things and then let some AI autocorrect fix it up for whatever reason rather than doing it properly.
109.
▲
by
rak1507
5y ago
More like ; than ,
110.
▲
by
rak1507
5y ago
Some sort of function that returns a variable number of arguments. It's basically the same as the list monad in haskell, and there are examples here https://en.wikibooks.org/wiki/Haskell/Understanding_monads&#
111.
▲
by
rak1507
5y ago
https://danluu.com/hn-comments/ is a good list
112.
▲
by
rak1507
5y ago
How do you know the price point is better? It's not on the website. Are you a customer?
113.
▲
by
rak1507
5y ago
Yeah I personally really like array langs so I was just wondering why other people don't.
114.
▲
by
rak1507
5y ago
Why is it still used then? Are there just no good alternatives? Or legacy reasons?
115.
▲
by
rak1507
5y ago
Auto completion? So saving a fraction of a second? Again... not sure I see the benefit here.
116.
▲
by
rak1507
5y ago
But.. why not use foo['bar'] vs foo.bar? Are the extra 3 characters so annoying you have to rely on a new library?
117.
▲
by
rak1507
5y ago
Not to be harsh but why would anyone ever use this? It's just some syntax sugar? (and over 3K loc... yikes)
118.
▲
by
rak1507
5y ago
This... doesn't look very good. What is that colour scheme? Orange and green?! Edit: I feel like I should say - if you are new to things, please don't feel discouraged by criticism. Everyone starts somewhere.
119.
▲
by
rak1507
5y ago
This just proves the parent commenter right. 'Software developers often have to run...' - yes! That is the problem! People shouldn't have to run all of that, but they do. If people thought about what they really needed rath
120.
▲
by
rak1507
5y ago
I find rank in APL/J to be much easier to understand (and much more powerful) than broadcasting in numpy.
More ›