Created
June 30, 2015 13:52
-
-
Save vindia/26e6ceb5f0f52b1d7ce2 to your computer and use it in GitHub Desktop.
Revisions
-
Vincent Oord created this gist
Jun 30, 2015 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,9 @@ sentences = [ 'Don’t like this trade.', 'Lets do it in the dark.', 'Foo bar' ] sentences.each do |sentence| puts sentence.downcase.gsub!(/[^a-z]/,'').split('').sort!.join('') end