#Lutece1727. Counting the Circles

Counting the Circles

Migrated from Lutece 1727 Counting the Circles

All parts of this problem, including description, images, samples, data and checker, might be broken. If you find bugs in this problem, please contact the admins.

Description

Lee Sang KiLee\ Sang\ Ki is an ACMer in UESTCUESTC.Due to the addiction of programming,he seldom talks with a girl.Of course,he doesn't have a girlfriend.When he came back home during the Spring Festival,his parents,grandparents,uncles and aunts were very worry about him.But every dog has its day,half year later,at LiRen Building B305B305,he came across a Korean female programmer.He thought she is really attractive so he thirsted for chatting with her.But he didn't know how to begin the conversation and meanwhile he couldn't speak Korean at all. So he asked his Korean friend,Song Zong KiSong\ Zong\ Ki for help.SongSong is an old driver in this respect,he sent 44 Korean sentenses to LeeLee and taught him how to read them.And then Sang KiSang\ Ki touched the girl's shoulder slightly and said:

an nyeong ha se yo

zeon i ssang gi i la go ham ni da

zi geum yeo za chin gu ga eop da

zi man nan neo ui wang za doe gu si peo yo

The girl was really shocked.She looked at LeeLee's sincere eyes and suddenly she felt his real heart.But she didn't want to say "YESYES" immediately so she wanted to give LeeLee a test.She told LeeLee:"As you know,there are many Korean characters consisting of a consonant letter 'ㅇ',which looks like a circle.I will number the characters in the sentenses you just said by 3636 hexadecimal.Every time I will give you the leftmost character's position LL and the rightmost character's position RR,you should answer me how many circles are there in the section[L,R][L,R] of your sentenses in 11ms.I will ask you 666666 times,if you get all the answer correct,I'm willing to give you a chance to build the relationship.But if you are wrong,I think we'd better not meet each other again cause I never ever want to have any connection with a suck programmer."LeeLee thought this is just a piece of cake,so he invites you to write a program for him to solve this problem,the reward for you is his signature photo.Can you help him solve it?

title

title

Input

The input contains exactly 666666 test cases.

Each test case in a line contains two 3636 hexadecimal integer LL and RR.(0LR3510)(0 \leq L \leq R \leq 35_{10})

Output

For each test case,print the answer on a separate line.

Samples

0 4
5 E 
F N
4
4
2

Resources

( ⊙ o ⊙ )!