0

I have the following Python code, which is 214 bytes long:
G=print
B=input
A=int
H,M,N,O,I,P,Q,J=map(A,B().split())
C=[I]*H
for R in range(J):K,L=map(A,B().split());C[K]=L
while 1:D,E,F=B().split();G(['WAIT','BLOCK'][A(E)<C[A(D)]and F=='LEFT'or A(E)>C[A(D)]and F=='RIGHT'])
Is there a way to redu...