The best solution would probably be to permanently associate a solution with a language version but I guess they didn't go woth that.
Right, the comment was meant for someone who might be confused as to where the function went :)
I can't speak for others, but if I recall correctly I submitted this solution around 2016 or 2017 when codewars was using an ancient version of elixir (something like 1.2). Obviously you would not use String.strip with 1.9 because it doesn't exist.
String.strip was deprecated in favor of String.trim, String.trim_leading, String.trim_trailing
it's better to use ctype_digit to check that the ticket contains only digits.
your solution returns true for isLucky('123.24');
did the same exact thing)))
yeah, it doesnt filter the entire array twice
The random tests don't check for false positives. Returning words is enough to pass.
Your solution - LOL. But it's incorrect: the simplest counterexample is "dy" and "nn".
There's Elixir 1.6 now, so to_char_list should be changed to to_charlist.
And I think the example in the description should be more similar to those in other languages.
i will add a translation
anagram?("mom", "oMo") === true
You may want to add translation to that kata.
Of course! :)
good use of cond
But did you have fun? :)