Your question is Palindrome String Program. Start with the requirements on the right.
Run and submit as often as you like. When you're ready, talk me through your approach or go straight to the code.
Creative Synergies Group uses short asset labels in review workflows. Implement a function that determines whether a label is a palindrome.
A palindrome reads the same from left to right and right to left. Compare characters exactly as provided: comparisons are case-sensitive, and spaces or punctuation are treated as ordinary characters.
Implement is_palindrome(text).
text, a string.true if text is a palindrome, otherwise return false.Use a two-pointer approach that compares the first and last remaining characters, then moves inward. Return as soon as a mismatch is found.
def is_palindrome(text):