main=do x<-getLine let (a:b:[])=words x a1=read a::Int b1=read b::Int c1=length [ 1 | c1 <- [a1..b1],(c1+a1+b1) `mod` 3==0] putStrLn $ show c1