It would be helpful to provide an actual definition of a 'bouncy number' rather than mere examples. More than one possible definition matches the given examples.
The grammar in this sentence is awkward, if not incorrect: "Timmy being the top coder he is has allowed some bad code through, you must help Timmy and filter out any injected code!"
It would be better to say: "Timmy, being the top coder he is, has allowed some bad code through. You must help Timmy and filter out any injected code!"
The kata is ambiguous because it is titled "Regex count" but the instruction do not specify that regex should be used. Either the title should be changed or the description should specify that regex should be used.
@Chrono79, exactly! anyway, it's a bad practice to use string or str as variable names in python because they are a module and a built-in, respectively. every other language uses line (except ruby which uses str, idk if it matters in ruby), so why not just use line or whatever in all languages?
Before that, it already says:
It would be helpful to provide an actual definition of a 'bouncy number' rather than mere examples. More than one possible definition matches the given examples.
You're not creating the var
sandwiches
, and that's why that error appears.No matter what I enter, I get NameError 'sandwiches' not defined.
Done.
The grammar in this sentence is awkward, if not incorrect: "Timmy being the top coder he is has allowed some bad code through, you must help Timmy and filter out any injected code!"
It would be better to say: "Timmy, being the top coder he is, has allowed some bad code through. You must help Timmy and filter out any injected code!"
The kata is ambiguous because it is titled "Regex count" but the instruction do not specify that regex should be used. Either the title should be changed or the description should specify that regex should be used.
doesn't matter in ruby or js. ruby uses different kind of thingys.
@Chrono79, exactly! anyway, it's a bad practice to use
string
orstr
as variable names in python because they are a module and a built-in, respectively. every other language usesline
(except ruby which usesstr
, idk if it matters in ruby), so why not just useline
or whatever in all languages?I guess it's good now, then.
In Python it's called
string
and both strings and numbers are passed as input, which I find confusing.Corrected the problem. Waiting for Unnamed or someone else to mark it as resolved.
Corrected the generation of a random-not-palindrome. It is lucky you found this problem since it only shows up randomly.
In terms of argument being called line, certainly a number can be a line. It is the argument name used in the Javascript version.
Of course, if you could suggest something better that could be a word, number, phrase, etc?
please see issue above
Racket random tests:
(And why is the argument called
line
is it can be a number? Is a number a line?)Loading more items...