4 ms·
Why use such a thing? Array languages are very powerful for dealing with high-dimensional data. R, matlab, octave, and Julia can all do this and are satisfactor
by wyc 10y ago
Why use such a thing? Array languages are very powerful for dealing with high-dimensional data. R, matlab, octave, and Julia can all do this and are satisfactory for most people. However, proponents claim that languages such as K are much more expressive.
The APL family gets a bad rap for being "read-only", but I think it's mostly because they've fallen out of favor and have become unpopular. People who have experience working with these languages can encode/decode incredible amounts of information to/from a few lines once they see "phrases" and "sentences" instead of "my cat chewed the 56k modem line". We don't write Integral() in calculus when we want to take an integral, so why not have similar shorthands in computation?
Here's the vocabulary of the sister language J for comparison:
http://www.jsoftware.com/help/dictionary/vocabul.htm http://www.jsoftware.com/help/dictionary/vocabul.htm
"The one-page thing":
http://code.jsoftware.com/wiki/Essays/Incunabulum http://code.jsoftware.com/wiki/Essays/Incunabulum
Naive K-Nearest Neighbors implementation:
https://github.com/wyc/snippets/blob/master/j/knn.ijs https://github.com/wyc/snippets/blob/master/j/knn.ijs
Community:
https://www.reddit.com/r/apljk/ https://www.reddit.com/r/apljk/
- minikomi 10y agoA nicer to look at J Vocab has been published recently: http://code.jsoftware.com/wiki/NuVoc http://code.jsoftware.com/wiki/NuVoc It's a fun language to use to do /r/dailyprogrammer puzzles.