Given a positive integer N, print all N bit binary numbers having more 1’s than 0’s for any prefix of the number.
The first line of input contains an integer T, denoting the number of test cases. Then T test cases follow. Each test case contains an integer N.
For each test case, print all N bit binary numbers in decreasing order in a newline.
111 110 101
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.