lookup function

cs50 leftover removed