A clarification would still be appreciated. For example, in test case find_all(35, 6), 107999 would be valid even though there is a zero after the one. Zeros that are not the first digit do count in the value of the number.
The test case shows (letter_count('arithmetics'), {:a=>1, :c=>1, :e=>1, :h=>1, :i=>2, :m=>1, :r=>3, :s=>1, :t=>2}) but the word 'arithmetics' only has one 'r' not three. Can't pass the test cases with that error.
A clarification would still be appreciated. For example, in test case find_all(35, 6), 107999 would be valid even though there is a zero after the one. Zeros that are not the first digit do count in the value of the number.
Your prime_number? method is so elegant, my solution was identical except for that method!
The test case shows
(letter_count('arithmetics'), {:a=>1, :c=>1, :e=>1, :h=>1, :i=>2, :m=>1, :r=>3, :s=>1, :t=>2})
but the word 'arithmetics' only has one 'r' not three. Can't pass the test cases with that error.timeout error. Passes test cases but timesout during execution of attempt :/