Thanks Bruce

I worked out another way to do it also, but no sure if it is correct but seems to work ok for me
b0=portb
b1=b0 & %11110000
b2=b1/16

also can you please explain
OPTION_REG.7 = 0 ' Pull-ups on for inputs

I am currently using external resistors for pull-ups and I would like to get rid of them if I can