added solution for 25 in ruby