[chapter3] update 3.1.2 completely