solved problems 28 and 38