Because results are more pleasant if you order them. Just a personal habit
It doesn't say you have to order the results, so why do you do it?
For some reason if you ORDER BY the results gives an error. So be aware of that.
Thanks a lot I didn't know that I could print the input!!
Here you can find another primality test kata without "puzzle" and guessing aspect: https://www.codewars.com/kata/5262119038c0985a5b00029f
You can see test input and you can debug your solution, see here how.
This kata is not well explained, I already resolve the tests but the submit part shows me errors that I can't see, this is a failure or a feature missing in codewars. We improve from our mistakes, without seeing the errors it's imposible to improve.
Nice kata for recalling basics.
P.S. Or for a basics recall. Which varian from these two is more correct "recaling basics" or "basics recall"?
there is a bunch of additional checks run when you make an 'attempt' - at 'test' it just checks the expected functions have been used, but it doesn't check the retured table values are matching the criteria, it does it at the 'attempt'
The error messages still say descending instead of ascending... (Ruby)
This comment is hidden because it contains spoiler information about the solution
Yes, functional emoji is all that matters!
Besides that, he's Hacker 'Sakana'. Search for its meaning in Portuguese ('c' instead of 'k', for the sound) >_<
I added the 'can' while rewriting the kata specification which was ambiguous; I had read a comment which said that loops could be nested and my own solution was implementing this so I didnt know there were no actual tests. Too bad :(
Don't try to decypher description. Attempt and read the response of the tests, it's easier.
I liked this Kata, but i do have a fundamental question!
Is there any particular reason why you would use WITH over a simple join? What are the benefits?