시간 제한 메모리 제한 제출 정답 맞은 사람 정답 비율
1 초 256 MB 712 358 304 53.901%

문제

팰린드롬은 앞으로 읽으나 뒤로 읽으나 똑같은 단어나 숫자들을 말한다. 일반적으로 대소문자를 구분하지 않지만, 공백은 구분한다.

다음은 팰린드롬의 예시이다.

  • Anna
  • Harrah
  • Arora
  • Nat tan
  • 9998999
  • 123 321
  • \$\$\$&&\$\$\$

모든 라인에 대해 팰린드롬인지 아닌지를 구분하는 프로그램을 작성하시오.

입력

첫째 줄에 테스트 케이스의 개수 n이 주어진다.

각 테스트 케이스는 한 줄의 텍스트로 이루어져있으며, 비어있는 줄은 없다.

출력

각 테스트 케이스에 대해 정답을 출력한다.

팰린드롬일 경우 "Yes"를 출력하고, 그렇지 않을 경우 "No"를 출력한다.

예제 입력 1

6
Nat tan
Palindrome 
123454321
Dogs and Cats
**()()**
1 221

예제 출력 1

Yes
No
Yes
No
No
No
W3sicHJvYmxlbV9pZCI6IjEwMTc0IiwicHJvYmxlbV9sYW5nIjoiMCIsInRpdGxlIjoiXHVkMzMwXHViOWIwXHViNGRjXHViODZjIiwiZGVzY3JpcHRpb24iOiI8cD5cdWQzMzBcdWI5YjBcdWI0ZGNcdWI4NmNcdWM3NDAgXHVjNTVlXHVjNzNjXHViODVjIFx1Yzc3ZFx1YzczY1x1YjA5OCBcdWI0YTRcdWI4NWMgXHVjNzdkXHVjNzNjXHViMDk4IFx1YjYxMVx1YWMxOVx1Yzc0MCBcdWIyZThcdWM1YjRcdWIwOTggXHVjMjJiXHVjNzkwXHViNGU0XHVjNzQ0IFx1YjlkMFx1ZDU1Y1x1YjJlNC4gXHVjNzdjXHViYzE4XHVjODAxXHVjNzNjXHViODVjJm5ic3A7XHViMzAwXHVjMThjXHViYjM4XHVjNzkwXHViOTdjIFx1YWQ2Y1x1YmQ4NFx1ZDU1OFx1YzljMCBcdWM1NGFcdWM5YzBcdWI5Y2MsIDxzdHJvbmc+XHVhY2Y1XHViYzMxXHVjNzQwIFx1YWQ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