This is a verified interview question from Hexaview-technologies. Candidates reporting seeing this problem in recent Online Assessments (OAs) and onsite rounds. Mastering "Longest Palindromic Substring" covers key patterns like Strings.
"Have the function SearchingChallenge(str) take the str parameter being passed and find the longest palindromic substring, which means the longest substring which is read the same forwards as it is backwards. For example: if str is "abracecars" then your program should return the string racecar because it is the longest palindrome within the input string. The input will only contain lowercase alphabetic characters. The longest palindromic substring will always be unique, but if there is none that is longer than 2 characters, return the string none."
Join thousands of developers practicing for Hexaview-technologies.