A,B = map(int, input().split()) cnt = 3 for x in range(23,26): if x >= A and x <= B: cnt -= 1 print(cnt)