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.
Fixed
I mentioned in the first sentence that the travelers are going to the trip along the river, but I will try to clarify the description. English is not my primary language too, so please let me know, if I make any silly mistakes.
Full test suie compiles with warnings:
I would also suggest adding message suppliers to assertions, at least in some basic/small random tests, for better feedback on failure. For details see https://docs.codewars.com/languages/cpp/authoring#custom-assertion-messages .
English is not my primary language so it might be a language issue, but for me initially it was not really clear what "crossing the river" means and why I need to account for all tributaries. Cannot travellers just, like, cross the river and move from the left bank to the right bank, so cost would be always 1? It took me a while to understand that the travellers want to trip along the whole river, starting at source, and reaching its estuary (word?).
Fixed
Fixed
Fixed. Thanks:)
This comment is hidden because it contains spoiler information about the solution
#include <iostream>
shouldn't be added to the initial code.Needs random test cases, but otherwise looks good. Fun kata!