Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

4
  • \$\begingroup\$ Here is the first working code. Coming back later for some more golfing. \$\endgroup\$ Commented Apr 22, 2014 at 17:05
  • \$\begingroup\$ My code is currently 1 character longer. I am looking for any possible way to golf further! \$\endgroup\$ Commented Apr 23, 2014 at 15:17
  • \$\begingroup\$ Not that you need my help, but you can save 14 chars by defining {puts}:|;, 5 chars by replacing R and W with - and > (allows to eliminate surrounding spaces) and 9 chars by dropping '> 'print (doesn't seem to be required by the question). \$\endgroup\$ Commented Apr 26, 2014 at 4:24
  • \$\begingroup\$ @Dennis Thank you. I'll surely implement some of your suggestions. \$\endgroup\$ Commented Apr 26, 2014 at 7:36