Operation.result this is especially bad. You're using the exact same variable for each result while you should only update the one of the instance your using execute one
all the constructors have nothing to do here...
This clearly showes that you know absolutely nothing to inheritance (or at least, you didn't at the time you completed the kata. I hope you wouldn't write that solution that way anymore...?), so don't vote your code as best practices, this is the worst thing you can do. Beginners won't know how much your solution is bad.
Look way down the comments, you need to subtitute in test area case:
bin = Alphabet['BINARY']; oct = Alphabet['OCTAL']; dec = Alphabet['DECIMAL']; hex = Alphabet['HEXA_DECIMAL'];
allow = Alphabet['ALPHA_LOWER']; alup = Alphabet['ALPHA_UPPER']; alpha = Alphabet['ALPHA']; alnum = Alphabet['ALPHA_NUMERIC'];
did you think about the sorting of the string with uppercase and lowercase? i failed because of this, hope i help
"Baab" --> "aabB"
but
"ABaab" --> "aabAB"
Operation.result
this is especially bad. You're using the exact same variable for each result while you should only update the one of the instance your usingexecute
oneThis clearly showes that you know absolutely nothing to inheritance (or at least, you didn't at the time you completed the kata. I hope you wouldn't write that solution that way anymore...?), so don't vote your code as best practices, this is the worst thing you can do. Beginners won't know how much your solution is bad.
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 think it's the fact your solution should be
O(n)
, and notO(n^2)
to pass the tests in time.This comment is hidden because it contains spoiler information about the solution
You can try with :
return [x,y]
Hi! I would love to practice PL/SQL in codewars :D
THere is none.
Thanks!
Look way down the comments, you need to subtitute in test area case:
bin = Alphabet['BINARY']; oct = Alphabet['OCTAL']; dec = Alphabet['DECIMAL']; hex = Alphabet['HEXA_DECIMAL'];
allow = Alphabet['ALPHA_LOWER']; alup = Alphabet['ALPHA_UPPER']; alpha = Alphabet['ALPHA']; alnum = Alphabet['ALPHA_NUMERIC'];
wow!! I love this solution!! Happy katas! :)
I really like this kata! make me think for all the morning how can I optimize time ejecution! Thank you!
did you think about the sorting of the string with uppercase and lowercase? i failed because of this, hope i help
"Baab" --> "aabB"
but
"ABaab" --> "aabAB"
for C++ I've found error:
in main function:
std::string DNAStrand(dna) --> std::string DNAStrand(std::string dna)
happy hacking!
Loading more items...