


Words are separated by one or more whitespace characters.
For the given string “Madam oyo cat”, “Madam”, and “oyo” are the palindrome words
The first line contains an integer 'T' which denotes the number of test cases or queries to be run. Then, the T test cases follow.
The first and only line of each test case contains the string S.
For each test case, print the number of palindrome words in the given string S in a separate line.
You do not need to print anything, it has already been taken care of. Just implement the given function.
1 <= T <= 10
0 <= |S| <= 10^5
All the characters of the string S contain whitespace, lowercase, and uppercase English letters only.
Time limit: 1 second
For Checking the word is palindrome or not: