EXAPUNKS

EXAPUNKS

View Stats:
First Mitsuzen HDI-10 puzzle
Someone has managed to complete this puzzle in 38 cycles, a feat which I am fairly sure is mathematically impossible. Even unrolling all my loops, not doing and clamping, and not even processing all the input due to size constraints, I still can only get down to 45 cycles. To actually properly validate and modify the input and loop indefinitely seems completely impossible. Is this person cheating?
< >
Showing 1-10 of 10 comments
No. Hint: 1.REPL 2.pipeline
I dunno about that. I've replicated pretty heavily on this puzzle and my best possible in this specific instance is 42, and that's cutting literally all the extraneous steps. I'm sure there's something obscenely clever to get it down to 41 or 40, but given that just getting through the motions to deliver the message takes guaranteed number of cycles... i find 38 implausible.

There are still quite a few ways to cheat by exploiting the RNG in a lot of the cases, where there's in some cases hundreds of cycles to be won.
I must really be missing something big then
Theres a way to clamp the value with no test instructions which saves a few cycles.
There is a simple way to output a value each cycle after some warming up, and it doesn't matter how long it take you to process the value (up to a point)

Also note that there is exactly 30 values to output.
Damn! Nobody told me it was impossible, so I did it in 37 cycles.



try avoiding TEST commands



the registers are capped at + - 9999 you can use this to avoid the checks

Also you can read a register using ADDI or SUBI




so
ADDI 9949 #NERV X
reads the output and sets the maximum to 50
Yeah made it to 36! And it's some of the most beatuiful code i have ever written. Using magic Numbers just makes it so clear...
You guys are awesome, I'm still at 200 cycles hahahaha
< >
Showing 1-10 of 10 comments
Per page: 1530 50