• ###### Marty3000commented on "Right truncatable primes in a given base" kata

Dear themanofthecat,

the solution of this kata seems to have an issue:
for base 16, it requires number 2047 in the solution-list.
My solution list ( without this number ) is rejected.
But 2047 ( = 89 * 23 ) is no prime.
i guess the issue is caused by an underlying issue of the fast_is_prime-function procvided by you.
fast_is_prime(2047) = True

There is a similar issue for base 19:
14044103 (5CEA66) => 739163 (5CEA6) => 38903 (5CEA) => 2047 (5CE)

• ###### Marty3000commented on "Right truncatable primes in a given base" kata

This comment is hidden because it contains spoiler information about the solution

No it's not.

• ###### lechevaliercommented on "Right truncatable primes in a given base" kata

However including all prime numbers in list allows to randomize tests a little more by asking for random ranges of prime sequence for a given base.

• ###### lechevaliercommented on "Right truncatable primes in a given base" kata

Iterative vs recursive only matters if you want to generate prime number list in order (BFS vs. DFS).
You should add in description that order doesn't matter.

• ###### themanofcatcreated a question for "Break the pieces" kata

Hey, I'd just like to know if such a shape is a valid input:

``````'\n'.join(['+----------+'],
['|          |'],
['|   +------+'],
['|          |'],
['+----------+'])
``````
• ###### themanofcatcommented on "Right truncatable primes in a given base" kata

This comment is hidden because it contains spoiler information about the solution

• ###### dolamrothcreated a suggestion for "Right truncatable primes in a given base" kata

I would suggest to make the task actually return all right-truncable primes, not just heads of sequences. IMHO, it just complicates things a little bit.

• ###### themanofcatresolved an issue on "Right truncatable primes in a given base" kata

Believe I've fixed the issues, thanks for correcting me

• ###### themanofcatcommented on "Right truncatable primes in a given base" kata

Sorry about that haha, I meant to change that in the hidden test cases
This is my first kata and there's not much in the way of instruction for this that I found, so thanks for this

• ###### Blind4Basicscreated an issue for "Right truncatable primes in a given base" kata

This comment is hidden because it contains spoiler information about the solution

• ###### themanofcatcommented on "Greed is Good" kata

This comment is hidden because it contains spoiler information about the solution

• ###### themanofcatcommented on "Greed is Good" kata

It seems like all of the random tests for python return 0, which it should not do.

• ###### Blind4Basicscommented on "Shelve your trophies" kata

'kay I figured that on my own, but thx for the answer.

Note that your solution is very slow. So you need to improve it otherwise you won't be able to push the number of tests. Note also that some maths could be used to reduce drastically the amount of computations in some cases. That might be interesting to add that. Maybe it could be worth of unpublishing the kata so that you can polish it a bit?

Mine being without optimisation (apart from the rules I check or not), I get things like this:

``````mine
Completed in 214.00ms
his
Completed in 3034.33ms
mine
Completed in 0.18ms
his
Completed in 0.47ms
mine
Completed in 0.78ms
his
Completed in 1.45ms
mine
Completed in 0.04ms
his
Completed in 0.20ms
``````