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.
Hey mate, this is not an issue with the kata.
You need to ensure that your digits match those specified in the description precisely.
Didn't find that one when I went digging around for similar Kata sadly.
I did find: https://www.codewars.com/kata/52a7099f8a4d9604bb000472 (which is focused around printing the 7bit number that lights the individual segments.)
Resolved
Added examples of all combinations.
Yep, that was an oversight on my end. Fixed it.
.
Occured to me after that I should have forked it, that's my bad.
Will do so next time.
Fair enough. I am interested in going about this the right way.
And perhaps, providing a cleaner translation off the bat next time haha.
Hope this cleans things up:
String imports added.
using namespace std
removed from initial.vector<int> scoreboard(const string &s)
proto added and initial updated.Expected result now calculated prior to Assert_Equal per loop cylce.
Out of curiosity, is this a common occurrence??
I have added language specific notes on return types and referred to the generic array in the description as a pair.
Have I gone about this the wrong way?
The intention was to get the feedback and address issues when I got the time, prior to approval....
Updated!
Thanks for that mate.
C++ translation. Please review and (hopefully) approve.
First translation I have provided, any feedback on the test cases is welcome.
I really like this solution.
Shows me that I included one too many steps, utilising min_element AND distance to retrieve the index of the next smallest element.