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.
What if the "shifted" string has a tie for the most common character?
It would be even better with highload tests :D
Funny kata! I enjoyed it
desription is short dence and also nice to reed.
I wish my companys documentation is written that way...
Description should be language-agnostic
Pretty much a duplicate of this kata.
Well, you're not afraid to invalidate existing solutions! :D ( Rightly - that's what Beta is for. )
Fixed.
You goddamn right! Now you get only letter, not object! Thank you!
letter
is encoded as{'l': 3}
. But it is a tuple. In JS, the appropriate encoding for that is as an array, not as an object ( witness all the hoops solvers are jumping through to get at the contents ).Use appropriate datatypes!
( Unimportant: the second value is never used. So why pass it? )
Yup :]
Thank you for feedback! Fixed, as per your advice.
Initial code has
return new String();
. I applaud this effort! More kata should give datatypes for their inputs and outputs.But it should be
return "";
, because JS distinguishesObject
s ( thatString
) and primitive values. And the return value should be a primitive string, not anObject
.Description changed, and this part removed from Pre-loaded.
Huh, right. My mistake. Came up with a bicycle. Thank you.
Do you not know about
String.prototype.charCodeAt
, or why is this here?Loading more items...