t = int(input())

def req(guess):
    print("? " + "".join(guess))

def out(ans):
    print("! " + "".join(ans))

for _ in range(t):
    n = int(input())
    guess = []
    right = True
    while right and len(guess) < n:
        guess.append("0")
        req(guess)
        o1 = int(input())
        if not(o1):
            guess[-1] = "1"
            req(guess)
            o2 = int(input())
            if not(o2):
                right = False
                guess.pop()
    ans = [""] * n
    m = len(guess)
    for i in range(m):
        ans[i-m] = guess[i]
    for i in range(n-m-1,-1,-1):
        ans[i] = "0"
        req(ans)
        o1 = int(input())
        if not(o1):
            ans[i] = "1"
    out(ans)



