You are given a string S. Your task is to determine if sum of ASCII values of all character results in a perfect square or not.
The first line of the input contains a single integer T, denoting the number of test cases. Then T test cases follow. Each testcase has a string S
Print 1 if the resulting sum is a perfect square, else print 0.
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.