Please Forward: Ruby Quiz Submission

From: "Robert Horvick" <robert.horvick@gmail.com>
Date: December 9, 2007 11:15:32 PM CST
To: submission@rubyquiz.com
Cc: "Robert Horvick" <robert.horvick@gmail.com>
Subject: Please Forward: Ruby Quiz Submission

I'm only a few months into learning Ruby but what the heck :slight_smile:

It attempts to print all possible loops of the same form (start from left, loop down and to the left, finish upwards). For example "mississippi" finds three loops.

$ ruby 149.rb mississippi
  i
  p
  i
miss
  si

i
p
mis
ss
si

missis
    ps
    pi

149.rb (1.94 KB)

···

Begin forwarded message: