N:=stdin nextByte- 49.{{}}do:(Q:=[:o|0to:N do:[:x|I:=-1.L:=o size.(o anySatisfy:[:v|x-(I:=I+1)+L=v|(x+I-L=v)|(x=v)])or:[L=N and:[o do:[:i|stdout<