Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
You can look at the tests by printing the input:
Troubleshooting - print the input
For this kata, therefore, if you type:
print(title, minor_words)
in your function, you'll be able to read in console which inputs you are failing on.
As for tests 6 and 9 here, just to get you started: you will find that test#6 is using
ab
as inputtitle
andab
as inputminor_words
; it is expectingAb
as output notab
- Why? Because if you re-read the kata description:"(b) considered to be an exception and put entirely into lower case unless it is the first word, which is always capitalised."
so you should always capitalise the first word, regardless of whether it appears in the "exception" words or not.
This comment is hidden because it contains spoiler information about the solution
Not a kata issue, your code mutates the input list, as the error's message says. Read this too: https://docs.codewars.com/training/troubleshooting/#post-discourse
Not a kata issue. Please read this: https://docs.codewars.com/training/troubleshooting
Please mark comments containing solution code as a
spoiler
.The source of your problem is given in the error message:
ImportError: cannot import name 'adjacent_element_product' from 'solution'
. Your function does not have the correct name, so the tests can't find it. Do not rename functions or classes you encounter in the trainer.Your function needs to return the generated string, you're printing it to the console!