News for hackers. Stuff that matters.
Re:J vs. K by Example by beagle3 on Friday February 05, 2021 @10:59PM (#26044012)
Do note that this is K2/K3 vs. J

J hasn't changed much, but K has. K9, the most recent incarnation, is much simpler and more generic than the version described here, and also significantly faster.

Re:J vs. K by Example by tluyben2 on Saturday February 06, 2021 @01:10AM (#26044532)
The latest k is also still under active development by Arthur and colleagues under Shakti. There are frequent releases to play with.
Re:J vs. K by Example by rscho on Saturday February 06, 2021 @05:21PM (#26050569)
I know a fair bit of J, but never used K. What do you mean by "more generic"? I'm interested.
Re:J vs. K by Example by beagle3 on Sunday February 07, 2021 @01:59AM (#26053240)
It has 3 data shapes: atom, list, dict. Lists of elements of the same kind are called a vector, are more efficient, and are like J/APLs one dimensional array - but semantically are the same as any other list.

A matrix is represented by a list of lists. No specialization there. You work on the 2nd dimension with “each”, on the 3rd with “each each”.

Integers are all 64 but, but storage expands and contracts based on actual range.

There is one operator for both “where” and “replicate”, one operator used for both “or” and “max”, similarly “and” and “min”.

K is less pure and prefers to reuse concepts like lists instead of having more complicated (though sometimes helpful) structures like multiple dimensions.

Hope that helps.