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
This comment is hidden because it contains spoiler information about the solution
Last line should be return null, per the problem description.
4-liner, cheating on whitespace doesn't count.
Nice solution!
thanks, Markus! nice one, as well :) I think I just need more practice with the streams to come to that level
And another one here :-)
yes
EDIT: "one liner" in O(N) here (for fun)
nice one-liner! very elegant! I think it needs O(n^2) time though?
Please avoid to use cryptic and short variable names as a good practice.
вместо String symbol = s.substring(i, i+1);
лучше s.charAt(i)