logoalt Hacker News

Programming in K

59 pointsby toshlast Thursday at 11:27 AM10 commentsview on HN

Comments

chrisaycockyesterday at 10:36 PM

I first encountered q/kdb+ at a quant job in 2007. I learned so much from the array semantics about how to concisely represent time-series logic that I can't imagine ever using a scalar language for research.

Fun fact: the aj (asof join) function was my inspiration for pandas.merge_asof. I added the extra parameters (direction, tolerance, allow_exact_matches) because of the limitations I kept hitting in kdb.

https://code.kx.com/q/ref/aj/

https://pandas.pydata.org/docs/reference/api/pandas.merge_as...

show 2 replies
koolalatoday at 12:10 AM

I wish there was a language like K that worked with single precision floats. Would be great to use with graphics.

show 1 reply
jjtheblunttoday at 12:45 AM

the github repo linked, under "manual.md", has a link which redirects to malware, such as that ostensibly to "k6".

show 1 reply
monster_trucktoday at 1:29 AM

K fucking rules if you're trying to minmax a game or balance your own.

Figuring out things like "what percentage of the time will my starting hand contain the cards I need for my deck to function, and if it doesn't, how many mulligans will it take" will basically ruin competitive MTG for you. I used to buy physical verisons of the decks I made it to top 500 with in Arena, stopped because it wasn't a fun challenge anymore (and lost all interest when they started dragging other IPs in, they'll never get another cent from me)