problem 1004 of pku online judge