Solving problem 124 and 127.