def prime(s,e):
flag=0
for j in range(s,e+1):
n=j
w=n/2
i=2
if(i==w):
flag=1
while i<w:
if(n%i==0):
flag=1
i+=1
if flag==0:
print(n,end=’\t’)
flag=0
time=int(input())
k=time
ss=[]
while time>0:
a,b=input().split()
ss.append(a)
ss.append(b)
time-=1
for m in range(k):
a=int(ss[0])
b=int(ss[1])
prime(a,b)
ss.pop(0)
ss.pop(0)
print(’\n’)
m+=1
this my code. it was working fine in jupyter. but the coding block console throws TLE error
