part a completed :D