Given a Integer array A of n elements. Your task is to complete the function PalinArray. Which will return 1 if all the elements of the Array are palindrome otherwise it will return 0.
The first line of input contains an integer denoting the no of test cases. Then T test cases follow. Each test case contains two lines. The first line of input contains an integer n denoting the size of the arrays. In the second line are N space separated values of the array A.
For each test case in a new line print the required result.
1 <=T<= 50
1 <=n<= 20
1 <=A<= 10000
111 222 333 444 555
121 131 20
For First test case.
A = 111 //which is a palindrome number.
A = 222 //which is a palindrome number.
A = 333 //which is a palindrome number.
A = 444 //which is a palindrome number.
A = 555 //which is a palindrome number.
As all numbers are palindrome so This will return 1.
If you have purchased any course from GeeksforGeeks then please ask your doubt on course discussion forum. You will get quick replies from GFG Moderators there.