4 ms·
Additional suggestion: ability to grade code. I see solutions that are a lot shorter than mine in code (2 labels, 5 instructions), but they take about 87 instru
by lucb1e 11y ago
Additional suggestion: ability to grade code. I see solutions that are a lot shorter than mine in code (2 labels, 5 instructions), but they take about 87 instruction cycles to get there whereas without labels you can do it in about 30 cycles.
- Lewton 11y ago... Without labels? Can you show that solution? Are you sure it works for robots placed on an infinite line?
- lucb1e 11y agoYeah, I was about to delete my comment (but now someone already replied) because I discovered the randomize button. My bad! The solution with a "speeding label" is the only solution I see. I also recognize the parallel with infinite loop detection now, like sugarcube commented already: https://news.ycombinator.com/item?id=10477109 https://news.ycombinator.com/item?id=10477109