Chapter 2 exercises done.