update example 4-8

update example 4-8 and bug fixed