Add solution and tests for listToNumber