I think it would be a good idea to add two more test-cases to the default ones. Namely the Cheshire cat and the one where 'shire' is surrounded by non-alphabetical characters.
Like I said, I tested "ya" and it returns "ayay", thus my confusion. I checked specifically for "ya" as well to see if it was the issue and it didn't work, so I'm guessing "ya" is not the test case. I can't figure out what's going on.
I have a technical problem with the Java version. I did this kata, all test were passed, but when I submitted it, I get the following message:
testtes3t5(TestPigLatin)
expected: but was:
test123(TestPigLatin)
0 Passed
1 Failed
0 Errors
I have a feeling, that in this kata the test classes are different in testing and in submission. In real test class there are no testtes3t5 test123 methods.
I think it would be a good idea to add two more test-cases to the default ones. Namely the Cheshire cat and the one where 'shire' is surrounded by non-alphabetical characters.
According to http://stackoverflow.com/a/25352300/2928562 String.charCodeAt() performs better than a regular expression..
Like I said, I tested "ya" and it returns "ayay", thus my confusion. I checked specifically for "ya" as well to see if it was the issue and it didn't work, so I'm guessing "ya" is not the test case. I can't figure out what's going on.
Added in description that y is not a vowel :)
the y must go after the "a" because is a consonant and you must add after this "ay" so the solution is "ayay".
Thanks
Thanks! It was not clear for me first time.
Test's tests are those that you can see for exercising.
Submit's tests are others tests that you can't see for passing the Kata.
I have a technical problem with the Java version. I did this kata, all test were passed, but when I submitted it, I get the following message:
testtes3t5(TestPigLatin)
expected: but was:
test123(TestPigLatin)
0 Passed
1 Failed
0 Errors
I have a feeling, that in this kata the test classes are different in testing and in submission. In real test class there are no testtes3t5 test123 methods.
This comment is hidden because it contains spoiler information about the solution
I guess many others also consider Y a vowel but it's an English game so... :)
I think the TLDR explains that pretty well. It says that the keywords may be found anywhere within either of the fields
JS translation kumited.
How to approve it ?
Actually this would have a bug with a false match {race: 'hob', home: 'bit'}... Maybe good for a test case?
I don't think one big regexp solution is really best practice, clever it may be but maybe a dynamic regexp from the keywords would be?
Loading more items...