« first day (705 days earlier)      last day (830 days later) » 

07:03
@coltim dang, that's really good
i was thinking group might be handy but it takes some work to get it back in sorted order
for example k9: {x@^',/'(1_')\:=x}"abracadabra"
@ktye yeah, here
with respect to brute force code generation - this repo is from early k7 days but it worked pretty well
iirc it doesn't do anything smart about timeouts - it just prevents you from running anything that could get into an endless loop
even then it generated surprising solutions
another take on that 'strip first occurrences until empty' could use flip:
{x@|1_'?:'^:',\|+.=x}"abracadabra"
but again, pain to sort and strip nulls
(^ is from k7)
07:33
@chrispsn @coltim could be a case where your 'undo group' comes in handy :)
improving on group-y, but not quite shorter:
{x(#x)^*:'.=x}\    / k7
 
4 hours later…
11:20
again, a domain adverb could be nice here... pseudocode ((*'=)_D)\:
but otherwise, best i can do is slightly tweaking @coltim's {x(#x)^x?x}\ or {x_/|*'=x}\ (k7)
(actually first is k7, second is ngn/k)
 
5 hours later…
16:25
@ngn thanks for the bounty!
@chrispsn yeh; I'm not sure if it mostly comes up in golfing, but I feel like there's opportunity for some additional builtins for manipulating data (e.g. splice, combining values, inserting/deleting stuff)
 
1 hour later…
ngn
ngn
17:42
@coltim `"\" fixed
18:11
@ngn I'm not sure if this is related to the overflow/arithmetic stuff, but _\dict segfaults
ngn
ngn
18:33
@coltim fixed. it was unrelated
but there's something wrong with the wasm version :(
ngn
ngn
18:48
git bisect is awesome - it found the problem
 
4 hours later…
22:59
is there any information about parsing K anywhere? I would look at some source code but... yknow
ngn
ngn
@rak1507 what kind of information?
how most implementations go about it and stuff like that I suppose
I've never really looked at programming language implementations before but I'm interested in trying to parse K seeing as it's statically parsable
idk probably too hard for me at the moment but it'd be fun to try anyway
ngn
ngn
@rak1507 i parse using recursive descent, it's the easiest way
there's no need for a separate tokenization pass
@rak1507 this is a short description of k's grammar:
 E:E;e|e e:nve|te| t:n|v v:tA|V n:t[E]|(E)|{E}|N
yeah, I've seen that before
ngn
ngn
@rak1507 try doing only numeric literals and dyadic verbs first
23:11
I'll keep that in mind
How come dyadic verbs?
I would've thought monadic would be fairly simple but maybe not
ngn
ngn
well, if you feel like it, do monadic too
i thought dyadic-only might be simpler as a first attempt
don't want to bite off more than I can chew
ngn
ngn
23:29
@rak1507 monadic-only would be too boring - the only possible program would be: verb verb .. verb noun
true
ngn
ngn
(or multiple nouns at the end, if you allow "noun noun" applications)

« first day (705 days earlier)      last day (830 days later) »