cswork / OA打开练习工作台

EpicOA #1

Palindrome Word

估计简单评测数据准备中,可先阅读题面

考点(AI 标注)字符串回文区间

A palindrome is a sequence that reads the same forwards as it does backwards. "abba", for e

Example 1

Input:

s = "abcdefccfed"

Output:

cdefc
fccf
ccf

Explanation: The function prints all palindromes of 3 or more characters in length contained in the string "abcdefccfed", which are case-sensitive. The palindromes "cdefc", "fccf", and "ccf" are found and printed, while others like "cac", "fcf", or "cfcfc" are not printed due to case-sensitivity.