Ad
  • Custom User Avatar
    1. the code is very concise - that is good
    2. readability is not very good due to the mysterious regexp
    3. regarding productivity: I've tested a simple code execution in a loop (100000 times) and compared results with my implementation and it is almost 10 times slower (320 ms vs 43 ms) - and that is bad (most porbably either due to String.split complex implementation or because it compiles RegExp object on every call)