Second exercise of ruby