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.
Nice kata for C++ training on parsers, error handling, and such.
With modern C++17 (variants and visitors, exception handling, string_view, and such) quite straightforward to
solve : just parse the way you describe the langage and... debug for errors.
Thus ... overranked IMHO
Note : would have needed a proper C++ translation (passing const std::string& and returning a std::string), pissed with those const char returning functions...*
Nice Kata, but.... in the description the line "If you have less than 2 boxes at any side, you will run out of boxes while carrying." is confusing, as it relates to the EXAMPLE and not to the general problem.
Very confusing, especially because the line is highlighted bold.
Took me som time to figure that out...
As a grandpa dev, I don't know sh... about Python...
And like this kind of puzzles... (see 'pentomino').
Can you make it C++ without me to forfeit ?
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
Thanks @quantage ! Will take a look at your solution...
Actually, in the description (and the note at the end) it is said that your C++ function should return ALL
possible solutions (it's just a func prototype), but for this kata all problems have EXACTLY ONE solution.
We could go 3 ways:
a- keep it like it is (and may be make the description/notes/hints) more clear,
b- add some cases with multiple solutions (with lexico sorting at the end, would be easy to test)
c- add some 'no solution' cases (but that was not my first intention.
Note: it was @@##++_ tricky to generate problems with exactly one solution, though.....
As said, IMHO voile issue is very sévère
I think this kind of kata is nice for overloading in C++, if not templates.
This comment is hidden because it contains spoiler information about the solution
Hmmmm...a true one liner kata ??
Should not tag 'array' nor 'algorithm' IMHO...
Would anyone tell me why this does not pass with 'std::execution::par' ??
Have a SEGFAULT when running the 'random cases' (all others work fine...)
There is a note in CPP REFERENCE about the clang compiler:
transform_reduce can be used to parallelize std::inner_product. Some systems
may need additional support to get advantages of parallel execution
E.g., on GNU/Linux, the Intel TBB be installed and -ltbb option be
provided to gcc/clang compiler.
Dude!!!
Very nice kata.. Had to take a paper and a pen on this one :-)
Nice solution !
Great kata
Loading more items...