completed skeleton code and preliminary lookup method