Are you submitting this code to CodeWars? Please first read the CodeWars submitting tutorial, you ought to submit a function that takes params as input and returns the output, not a full-working UI for other uses.
The first Woof! wasn't counted because the second sentence/letter has woof 27 times, thus making the test invalid. The task description says: in case when any of the woof-sentences has more than 26 woofs, you should return just barking!.
This comment is hidden because it contains spoiler information about the solution
Are you submitting this code to CodeWars? Please first read the CodeWars submitting tutorial, you ought to submit a function that takes params as input and returns the output, not a full-working UI for other uses.
Example:
I changed it to show
A: {a}, B: {b}
instead of[{a}, {b}]
Duplicated some code, and I think it's done!
This comment is hidden because it contains spoiler information about the solution
Is it okay now?
It is fixed
std::string::size_type
is a type ofsize_t
(aka.unsigned long long
oruint64_t
). These are much shorter namesThanks
But I made a
toString()
method to show them as (x
,y
)I may need some more advice: how to label a segment?
It reads expect, not except
Added. Forgot to make it resovled 😁
I solved the Kata. Were there any
NaN
s?The first Woof! wasn't counted because the second sentence/letter has woof 27 times, thus making the test invalid. The task description says: in case when any of the woof-sentences has more than 26 woofs, you should return
just barking!
.Loading more items...