Write a function called gregs_e_tagger that takes a string as an argument and inserts “greg” in the middle of the string, and then returns the new “greg-i-fied” string. For odd length strings, consider the “middle” to be left of the middle character.
I get a message that states, “‘str’ object has no attribute ‘insert’” - However, my code does return the requested objective but it will submit as a solution. Any advice would be greatly appreciated - Thank you in advanced for any help!
sure this is accurate? I get taken to a review section.
that takes a string as an argument the description says. The exercise seem to test with strings by calling your function with string arguments, while your calls pass list as arguments
Yes, that is the right link. It was a question to a quiz, so it may not take you to the exact page, my apologizes. I could screen shot it if that would help?
Hi, I’ve just been doing the same practice quiz and it won’t let me pass this question. My code seems to work correctly when I’ve tested it, but when I check my answer I’m getting " gregs_e_tagger did not correctly insert "greg" into the middle of the string".
It was a question on one of the 10 minute practice segments on my dashboard but I can’t get back into it to link it now, it’s just taking me into different practice questions (same thing when following seraph76’s link in the original post).
There wasn’t an error message generated by the code itself, I just got
when trying to check my answer and there wasn’t an option to view the correct solution.