Ad
  • Default User Avatar

    Surprised by such an elegant solution. I also used symbols as numbers.
    But I put the result in array []. It turned out faster than yours, but harder to understand