4th challenge in ruby, with 2 solutions