All submissions for this problem are available.
Arora is a content person because, his name can be spelt the same, when seen from both left and right sides, ie. a palindrome. Seeing this, his friend, gagan, also wanted to have something unique about his name. So, he finds out, that by changing a single letter of his name(gaga'g'), his name also becomes a palindrome. Arora has many other friends and want to find out the same. They seek your help, to find out if the same can happen with their names. Remember, just a single digit can be changed.
- The first line of the input contains an integer T denoting the number of test cases.
Next T lines contains a string S consisting of lowercase alphabets.
Print 'yes' (without quotes) if it is possible, else 'no'.
- 1 ≤ T ≤ 100
- 1 ≤ S ≤ 1000
Input: 2 arora abcd Output: yes no
|Time Limit:||0.5 sec|
|Source Limit:||50000 Bytes|
|Languages:||C, CPP14, JAVA, PYTH, PYTH 3.6, PYPY, CS2, PAS fpc, PAS gpc, RUBY, PHP, GO, NODEJS, HASK, SCALA, D, PERL, FORT, WSPC, ADA, CAML, ICK, BF, ASM, CLPS, PRLG, ICON, SCM qobi, PIKE, ST, NICE, LUA, BASH, NEM, LISP sbcl, LISP clisp, SCM guile, ERL, TCL, PERL6, TEXT, SCM chicken, CLOJ, FS|
Fetching successful submissions