l,r=map(int,input().split()) if l<=295 and 417<=r: print(2) elif r<=295 or 295