You are viewing a single comment's thread. Return to all comments →
I'm stuck.. Getting timeout after 10th test ;/
import sys def check(l, r, x, y, p): for i in range(l-1,r): if (y-(p[i][0]*x)-p[i][1]) < 0: return 'YES' return 'NO' tests = int(input()) lines = [] queries = [] i = 0; for i in range(0,tests): l0,l1 = map(int,input().split()) lines.append([ l0, l1 ] ) queries_n = int(input()) for i in range(0,queries_n): q0,q1,q2,q3 = map(int,input().split()) sys.stdout.write(check(q0,q1,q2,q3,lines) + '\n')
Seems like cookies are disabled on this browser, please enable them to open this website
Geometry Queries
You are viewing a single comment's thread. Return to all comments →
I'm stuck.. Getting timeout after 10th test ;/