provided solution for 21-th problem