Ad
  • Custom User Avatar

    OCD says capatalized should be spelled capitalized :)

  • Custom User Avatar

    Only one test in Java as well

  • Custom User Avatar

    Hello, I'm new here. I've done many of the most completed 8 kyu JavaScript Kata(s) (low hanging fruit). The top answer for all that I can remember was one line of code. I always thought it would be better to spread it out over a few lines using descriptive variable names for readability. Since everyone seemed to be doing it in one line, I started following suit to the best of my ability. This is the first kata I did in one line where none of the top answers on the page were done in one line. To be fair, I learned lots of new coding shortcuts (map, =>, split/join) where before I would have used large for loops (I love this site for that), however it's probably better not to try to get it in one line, but rather aim for readability and best practice (especially for someone starting out). Right?

  • Custom User Avatar

    I agree. I'm new here and I'm still working on all the low hanging fruit. Most of the top answers I've seen so far have been one liners (and very enlightening). I was shocked this solution wasn't at the top of the list. Even people who aren't programmers know there's a formula for summation (no offense). This was my first upvote for best practice.