Practicing algorithm questions.