圆环问题,为啥a不到。。。
T = int(input()) for x in range(T-1): n = int(input()) a_1=[] a_2=[] for y in range(n-1): a_1 = list(map(int,input().split(" "))) a_2 = list(map(int,input().split(" "))) a1 = sorted(a_1) a2 = sorted(a_2) for i in range(len(a1)): for j in range(len(a2)): if a1[i] == a2[j]: print ("YES") elif a1[i] != a2[j]: print ("NO")
全部评论
(3) 回帖