The _minMovements method accepts an array of integers in the range [1-3]. Imagine the input array are a road you are traveling. Each integer in the array represents an obstacle on the road as you are moving forward. The road always has 3 lanes and you begin in the middle lane. At any time you may switch to any of the other 2 lanes.
Write an algorithm that would analyze the array and determine the minimum number of lane changes you would need to make to get to the end of the road.