Create chapter2 common classes and sovle Question1