Notes for Design and Analysis of Algorithms