Post #4308297
2026-08-01 07:45 UTC
I was dreading have to port and test some finicky code from python to C but then I realized that for my uses, there's only 201 possible inputs to the function, each of which results in like 24 bytes of output
I can just make my python code enumerate them all, stick them in an array, and now the C code never needs to generate shit
Replies (3)
-
@foone@digipres.club 2026-08-01 07:47
why debug a bunch of bitfiddly C code when you can just waste 5kb of code space?
-
@hazz223@mstdn.social 2026-08-01 08:01
@foone@digipres.club I love it when really “dumb” solutions are actually the best. It’s almost like putting a middle finger up to science.
-
@glitchcake@tech.lgbt 2026-08-01 08:21
@foone@digipres.club sounds like a fun zig project. One could do a similiar enumeration in comptime and have a similar static lookup table binary. Could be a fun nerd snipe to someone