n=int(input()) l=[1]+list(map(int,input().split())) for i in range(1,n+1): l[i]*=l[i-1] q=int(input()) for i in range(q): p,L,R=map(int,input().split()) if l[R]//l[L]>=p: print("Yes") else: print("No")