Problem3 done.