(a,b)=list(map(int,input().split())) for k in range(a,b+1): ss=1 if k==1: ss=0 else: for i in range(2,k): if k%i==0: ss=0 break if ss==1: print(k)