solving problem 028