Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
This comment is hidden because it contains spoiler information about the solution
In JavaScript, which is overall more efficient? Using IFs statements, Swith-Case, or K-V pair object with anonymous function? I have seen people using IFs- S-C and my self using K-V objects(something I picked from C# unfortunately).
Tests need to be revised in several languages. With a random string of length 10, a possible input would be
"iissssssso"
, which should return[340282366920938463463374607431768211456]
, with a 39 digits number.[]int
in Go is unable to hold this, but random tests generate strings of length comprised between 20 and 40. Python and Ruby are ok since they have integers of arbitrary size. I don't understand how tests are made in Haskell, but the output should be[Integer]
and not[Int]
. COBOL, Rust, Groovy and JS have tests correctly adjusted. C has no random tests (there's an issue already opened about that). Typescript has strings up to 11 characters, which I think may generate overflow (?). Other languages need to be checked. Actually, tests should be rewritten for languages having big integers and use them.Pretty nice kata, but if you make a state about invalid charcters you should make a test for it, encurageing those who make this kata to handle such outcome.
This comment is hidden because it contains spoiler information about the solution