Skip to content

unlockpattern

bradendubois edited this page Nov 8, 2021 · 9 revisions

Unlock Pattern

ID: unlockpattern

Difficulty: 1.6

CPU Time: 1 second

Memory: 1024 MB

Solution

Since the pivots are on a unit grid, one can read in all three lines and store the x, y positions of each pivot, and then go through from 1 to 9 in order and calculate the distance (basic trig!) between pivots 1 to 2, 2 to 3... and add the distances to a running total.

Clone this wiki locally