fix some bug
finish problem2