educative.io

Incorrect example on slide

On slide 2 of examples, the given string “oifvghsaashgnkrjgjrkn”, the solution given is “ghsaashg”, with the explanation that there are two substrings with longest length 8, we return the first palindrome. BUT, the second palindrome “nkrjgjrkn” has length 9. Although I understand the point the slide is meant to make, kindly provide correct example and solution for it.


Course: https://www.educative.io/collection/10370001/5500262945128448
Lesson: https://www.educative.io/collection/page/10370001/5500262945128448/6629058786099200

1 Like

Hello @Kshitij_Jindal,

You are correct in mentioning that the second palindrome is of length 9, which is the correct answer for the provided example.

The suggestion will be incorporated and the changes will be live soon. Thanks.

Feel free to share more suggestions and feedback. We’d be happy to help.

Happy learning!