i need a small formula for the below case.

i have set of data in A,B columns.. also i have a table like below..

a1 a2 a3
b1 b2 b3
c1 c2 c3

these values may or may not be present in the "A" column.

Initially the formula need to check the "a1" in "A"column.if it presents it should print the
value which is same row in "B" column, in the same a1 cell.

thanks in advance...