Problem 1165 · Easy

Single-Row Keyboard

Type a word on a keyboard whose keys sit in a single row, with the finger starting on the first key, and total the distance travelled. The visual places the keys on a strip and draws the movement between consecutive letters.

Open the interactive visualisation