a,b = map(int,input().split()) cnt = 0 n = [23,24,25] for i in n: if a <= i and i <= b: cnt+=1 print(3-cnt)