add my solution to ex2.12-ex2.29
add my solution to ex2.12-ex2.29