#31748: python解法


alanyeh10@gmail.com (皮卡)

學校 : 高雄私立正義高級中學
編號 : 165015
來源 : [49.213.187.253]
最後登入時間 :
2022-11-18 11:44:14

while True:
    try:
        N=int(input())
        for i in range(N):
            i=list(map(int,input().split()))
            hour=(int(i[2])-int(i[0]))*60
            time=abs((int(i[1])-int(i[3]))-hour)
            if i[4]<=time:#同時到也行
                print('Yes')
            else:
                print('No')
    except:
        break