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
An invisible U+00ad character is hidden there as the variable name.
The instruction should be made more clear
(int)
was added to castvector.size()
to typeint
fromunsigned long
orstd::size_t
. If you don't add it, there will be compile time warning.std::pow
is the standard C++ function.pow
was derived from C stdlib.I'm not an expert but, IIUC, there are more efficient solutions here. This one is O(n log n) due to sorting. But there are some that use either
std::map
or vectors to keep counts of each letter in each string. Those should be O(n).PEP 8 (the official style guide) literally advises against using lambda expressions.
Two questions:
(int)
beforevector.size()
?std::pow
instead of justpow
? The latter works fine.To avoid copying of a std::vector
What's the reason for changing the function signature?
What's the point of changing the signature of the function?
I find it really weird that Haxe doesn't have a function or a method to retrieve a maximum from an array :S
How does this actually work? I understand that an unnamed parameter is used here. But how is it passed to the
abs
function? I cannot find anything about it in the documentation.[updated wiki link](https://en.wikipedia.org/wiki/Guard_(computer_science)
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
Loading more items...