Create chapter6.erl