No test case is passing

Am enable to understand why not even one test passed .
Code

Hey @vg5823967
It’s not necessary that all numbers given in the array are single digit. What i mean that Your code fails for test cases like:
5
109 113 113 123 125
where the elements of the array are not single digit.
For the above test case, your code gives:
0 1 1 1 1
1 0 1 1 1
1 1 0 1 1
1 1 1 0 1
1 1 1 1 0
which is not obviously the correct ans. Try and dry run your code for the above test case and try to figure out your mistake.

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.