Added professor function. Query consists of last name