Added Ruby exampl

Added Ruby example following the style of the other examples.