Live data from Hacker News

Stages of Denial

beyondloom.com

41–50 of 119 posts

Re: Stages of Denial

#41
The uncanny rapport I feel by reading "lazy Tuesday afternoon, visiting The Orange Website, self-consciously averting your eyes from the C compiler output in a nearby terminal" builds enough trust that I'm willing to pay attention to what John Earnest (IJ or RtG) has to say about this. He's a great writer.

Naming things is hard. It's one of the 2 most difficult problems in CS, along with cache invalidation and off-by-one errors. Of course, in this context I mean "CS" as "Computer Science", not "CouchSurfing".

For the K programming language, meanings are specifically defined. In the article:

"The word “ordinal” can mean anything, but the composition That's fine for the K compiler, but not for Google Search, or grep. I use "Unique names are more useful for addressing (e.g. IPV6) but common names are more memorable (e.g. a URL. Translators (e.g. DNS) can't be perfect when there's a one-to-many or many-to-one correlation, but they try their best.

K does well to enforce structure, but in the process, makes it very hard for the programmer to find examples and other documentation. I guess that's why the language hasn't become as popular as other languages, whose syntax is sufficiently familiar to be legible and memorable but unique enough to be searchable.

Re: Stages of Denial

#42
post #21
post #9

I'm torn. Not about the conciseness of the language overall, but about using symbols vs. names. I do see how the symbols make things more concise, less clutter, and can even make it easier to grasp a piece of code if you are deeply familiar with them[1]. On the other hand, there might be a limit. I do know how it is to use the Haskell lens package only occasionally, and then having to lookup again what the operators…

The lens library has a reasonably consistent visual language baked into it: - Operators containing `%` apply a function to the target (mnemonic: % is "mod" in many languages). - Operators containing `=` have a `MonadState` constraint and operate on the monadic state. - Operators containing `~` operate directly on values. - Operators starting with ` - Operators starting with ` - Operators containing `@` operate on ind…

You wouldnt make it compact, so the new dreaming intern joining your codebase would be able to gloriously produce changes rapidly and get hired under the well intentioned smiles of the rest of the team.

Instead, in the kdb team I joined recently (a one-letter, symbol heavy language used by quants), nobody can remember what things do, nobody has time to teach you the insanity of code older than 2 months, and you re instead spending weeks "learning" under the heavy sighs of everyone suffering from the new burden guy.

Why do you want to do things compactly rather than with clarity?

I wish google could search for one-letter language specific symbol so I could ask "what does -9! do on type J vs type C" (nonsensical exemple, I cant remember types without looking at the type table, but I think -9! transforms a bit array into an object)

Re: Stages of Denial

#43
I already have problems reading arrow/inline functions... for example where a method is called with a function that returns a function... if there is one more (async) call in there my brain starts smoking.

Re: Stages of Denial

#45
post #23

Just replace K and JavaScript with German and English to see the vacuity of this argument. Either of several possible representations can become native to one’s thinking. The question is which is a better aid in reaching some non-arbitrary goal. The only merit of K presented and emphasized here was the supposed brevity of its programs. Personally I’ve found the habitable zone somewhere that allows for more air betwee…

How about this: K is an interpreted language, but your whole program's source code plus the interpreter plus the whole database engine fits inside your server's L1 cache, so K programs tend to be faster than their C equivalents (in addition to all the array operations being highly optimized).

And you don't get to waste time scrolling, your typical module's code fits on your single screen.

Re: Stages of Denial

#46
Hint: K is the name of the central character in Franz Kafka's The Castle, as well as that of The Trial.

> "The term "Kafkaesque" is used to describe concepts and situations reminiscent of Kafka's work, particularly Der Process (The Trial) and Die Verwandlung (The Metamorphosis). Examples include instances in which bureaucracies overpower people, often in a surreal, nightmarish milieu that evokes feelings of senselessness, disorientation, and helplessness. Characters in a Kafkaesque setting often lack a clear course of action to escape a labyrinthine situation. Kafkaesque elements often appear in existential works, but the term has transcended the literary realm to apply to real-life occurrences and situations that are incomprehensibly complex, bizarre, or illogical."

~ https://en.wikipedia.org/wiki/Franz_Kafka#%22Kafkaesque%22

Re: Stages of Denial

#47
I recently started using rust-analyzer with vscode.

One common sight is this:

thing

  .stuff()  

  .other()  

  .whatevs()

Each of the calls returns a different type. Rust-analyzer displays the return type of each call to the right of it.

I imagine something similar could reconcile the benefits of terseness with readability and discoverabilty.

The blog post already has the prototype:

+ / ! 100

plus reduce range 100

Imagine the second line being added in by your ide in a light gray.

Re: Stages of Denial

#48
This is a category of cursed knowledge which causes psychic damage to the reader.

When you go down certain rabbit holes you develop a fascination with obscure forms of programming and start to realize it has some powerful benefits of which you can never take advantage because it isn't widely adopted.

To free yourself from this curse write ten regular for-loops in C and say a prayer to K&R while tighly holding your copy of The C Programming Language.

Re: Stages of Denial

#49
post #34
post #16

Earlier quoted context omitted.

Been doing k for a bit (under a year). A single glance is optimistic, but probably only took me a few seconds. Almost certainly faster than any equivalent code in any other language. It's even easier if you give it a nice name, like "fib".

What kind of projects does K get used in?

This website has a few companies which use K: https://github.com/interregna/arraylanguage-companies

Re: Stages of Denial

#50
post #13

Earlier quoted context omitted.

The trouble in Haskell is that an operator like %%@~ is just an arbitrary name. In languages like K or APL, the combination of symbols is the actual definition.

As APL shows, you then need quite a large alphabet of symbols, though. But I'm not strongly in either camp. A few common branches of mathematics taken together have quite a large alphabet of symbols, too, and we work well with it. It feels like symbolic notations can seem obtuse at first and be hard to get into, but once you're used to it the alternative may appear worse.

> As APL shows, you then need quite a large alphabet of symbols, though.

I count 71, which doesn't seem like a lot.

Post reply on HN