Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I can see structure in most new programming languages I'm exposed to. I might not immediately understand what the code does, but usually there's some sense of rhyme and reason.

Though most languages are not as terse as this.



These languages are from a different branch of the computer science language tree. The verbs are different. The same verbs usually work similarly for all data types.

Each of those symbols (verbs) are jam-packed with meaning, and most looping is implicit or very natural, and overall code constructions are very terse.

It's like reading a nice short poem rather than a 700 page book.

It can go too far, of course; there is some middle ground to be found.

If you have time, reading into the language a little more deeply may be illuminating, because it changes the way you think about the very nature of the task at hand.


Aaron Hsu has a bunch of talks on YouTube that cover this. He argues that his compiler that translates APL to run on GPUs (or something like that), is much more coherent than the versions he wrote in scheme and other languages. It's easy for him to see at a macro level, what the code is doing. There's no need for boilerplate either. Pretty cool stuff.

Note that I'm not advocating that everyone should do APL for all uses. I adore Python and think it's awesome. I'm just saying these languages deserve more love than they get.


In some of the example programs written in KAP (my APL derivative), I tried to write it in a style that makes people unfamiliar with the array style more comfortable.

This code could of course have been written in a style similar to some of the more extreme examples, and they would have been significantly shorter in that case.

https://github.com/lokedhs/array/blob/master/demo/advent-of-...


Thanks, that does look a lot more approachable.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: