Code Eval Challenges Solved in Ruby