CompSci 161: Design and Analysis of Algorithms