Problem

Return a new array that is the given length-3 array rotated one position to the left.

Examples

  • rotateLeft3([10, 20, 30]) -> [20, 30, 10]
  • rotateLeft3([1, 2, 3]) -> [2, 3, 1]
  • rotateLeft3([8, 8, 2]) -> [8, 2, 8]
Compile and test (Ctrl+Enter)