added solutions for ex 1-5.