problem 13 finally worked out