Ad
  • Custom User Avatar

    In the example where it looped right I thought the end values would end up in reverse order at the beginning of the array e.g. loopArr([1, 5, 87, 45, 8, 9], 'right', 2) => [9, 8, 1, 5, 87, 45]. You should change the examples so there are not two of the same values for clarification, but other than that good problem!