Given a binary input that represents binary representation of positive number N, the task is to find binary representation of N-1. It may be assumed that input binary number is greater than 0. The binary input may or may not fit even in unsigned long long int.
The first line of input contains an integer T, denoting the number of test cases. Then T test cases follow. Each test case contains binary representation of the positive number N.
For each test case, print the binary representation of number N-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.