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.
Ruby, both sample tests and on submit:
Clarifying that ' alone does not count as a word would be nice.
Overall, it was a fun and interesting kata.
Lua translation!
After seeing solution it appears instructions are quite poor and solution matches values like this one : '''won''twon't''' … (!?)
Random test says its faulty and doesn’t provide the value under test, only expected result.
Log:
This is the input argument from the Top3 function:
"a a a b c c d d d d e e e e e
e e e e DDD ddd DdD: ddd ddd aa aA Aa, bb cc cC e e e
//wont won't won't
, e ..
...
' "
This is the error it generates:
Test Failed
Expected is <System.Collections.Generic.List
1[System.String]> with 0 elements, actual is <System.Collections.Generic.List
1[System.String]> with 1 elementsValues differ at index [0]
Extra: < "'" >
How can you possibly send an empty list if there is clearly multiple frequently used words in the input?
The "Ties may be broken arbitrarily." is broken in C#. The last random test generates error because of it. After like 10 time running the tests, RNG was on my side and I passed the test ... Someone else suggested tie breaker should be alphabetical, which would make a lot more sense imo.
Maybe specify on the "other characters" part a bit more. If the problem wanted me to avoid ANY character outside of the parameters it sure used a poor example and poor test cases.
Hi all! I have some questions about the requirements that have to be met:
I apologize for repeating questions which have been asked before by members of the community. Unfortunately, I was not able to find satisfactory answers to those questions. Thanks for your help :)
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
The test cases should include the '_' character. The random tests include them while the test cases don't. This is important since this is the difference between /W and [a-z].
(I can't find how to remove commenents and forgot to label it properly)
Lacks tests for words that begin in apostrophe.
//Apostrophes can appear at the start, middle or end of a word ('abc, abc', 'abc', ab'c are all valid)
Assert.AreEqual(new List { "'abc", "abc'", "'abc'" }, TopWords.Top3("'abc, abc', 'abc', ab'c"));
Scala translation
Loading more items...