Back to problems

Minimum travel path for a pen-plotter to draw given strokes

Algorithm · Waymo · Hard

Problem: Find the least-distance route for a pen plotter that must render specified strokes Build the routing logic for a pen-plotter that draws a shape on a sheet of paper. The input contains n strokes, where every stroke is a straight segment specified by its two endpoints. Each supplied stroke has to be drawn exactly once. The pen can move in either of these modes: Pen-down (drawing): Traveling along a stroke deposits ink, and that length counts toward the route length.…

Checking your access…