#C4957. Special Palindrome Checker
Special Palindrome Checker
Special Palindrome Checker
A string is considered a Special Palindrome if it meets two conditions: (1) it reads the same forwards and backwards, and (2) its length is even. Formally, a string \(S\) is a special palindrome if \(|S| \equiv 0 \pmod{2}\) and \(S = S^R\), where \(S^R\) denotes the reverse of \(S\).
Given a string S
, determine whether it is a Special Palindrome. Output 1
if it is a Special Palindrome, and 0
otherwise.
inputFormat
The input consists of a single line containing the string S
. The string may be empty and can contain any ASCII characters.
outputFormat
Output a single integer: 1
if S
is a Special Palindrome, otherwise 0
.
abba
1
</p>