Skip to main content
1 of 4
Tzlil
  • 61
  • 1

Snake algorithm that minimizes straight lines

how can i find the non-self-intersecting loop that uses the least amount of straight lines (curves left/right as often as possible every turn) and still loops back on itself?

Heres an example we have calculated for 8x8: Image

Here is an example we have calculated for a 6x6: Image

Tzlil
  • 61
  • 1