C: The reference solution is not correct. An example from random_tests:
Expected 38, but got 39. Input: "FNBZVPFQOPKKHEXRQJ IHFJSCONRSL XOAVYFANIEMSBQOHWMGDULMADPCUGCUCQJNOOCQWGSDXXGDSTKVMKWMNKOHQFAIWJVZNX"
Both Python and JavaScript reference solutions return 39 for this input.
Ignore spaces altogether
If the string contains a number, return -1.
These side quests add nothing to the primary task, and should be removed. Uninteresting input preprocessing and validation have been done.
Testing with valid inputs only means no existing solutions will be invalidated.
You have missed this part in the description --> Spaces should not be taken into account.(ignore spaces altogether)
Spaces should not be taken into account.(ignore spaces altogether)
Very unclear on how spaces should be dealt with. Gave up only because of that.
kata hint != kata suggestion
Fixed.
This comment is hidden because it contains spoiler information about the solution
I checked, I didn't find any errors. This typo was as soon as this kata was released. And then it was corrected. If I misunderstood something, please write about it.
The sample tests expect a function named max_len_wiht_condition but the final tests expect max_len_with_condition (Python)
max_len_wiht_condition
max_len_with_condition
Slow as heck I am
👆 The explanation is correct
No two letters N,O,P can be adjacent to each other in a substring, so:
N
O
P
NOPN OPNO => NOPNOPNO => N, O, P, N, O, P, N, O => 1
NOPN OPNO
NOPNOPNO
N, O, P, N, O, P, N, O
So given 'NOPN OPNO', ignoring space is 'NOPNOPNO'. this somehow results to 1?
Loading collection data...
C: The reference solution is not correct. An example from random_tests:
Both Python and JavaScript reference solutions return 39 for this input.
These side quests add nothing to the primary task, and should be removed. Uninteresting input preprocessing and validation have been done.
Testing with valid inputs only means no existing solutions will be invalidated.
You have missed this part in the description -->
Spaces should not be taken into account.(ignore spaces altogether)
Very unclear on how spaces should be dealt with. Gave up only because of that.
kata hint != kata suggestion
Fixed.
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
I checked, I didn't find any errors. This typo was as soon as this kata was released. And then it was corrected. If I misunderstood something, please write about it.
The sample tests expect a function named
max_len_wiht_condition
but the final tests expectmax_len_with_condition
(Python)Slow as heck I am
👆 The explanation is correct
No two letters
N
,O
,P
can be adjacent to each other in a substring, so:NOPN OPNO
=>NOPNOPNO
=>N, O, P, N, O, P, N, O
=> 1So given 'NOPN OPNO', ignoring space is 'NOPNOPNO'. this somehow results to 1?
or?
Loading more items...