Skip to content

Instantly share code, notes, and snippets.

@ohnishiakira
Created June 28, 2011 22:01
Show Gist options
  • Save ohnishiakira/1052346 to your computer and use it in GitHub Desktop.
Save ohnishiakira/1052346 to your computer and use it in GitHub Desktop.
String#to_dvd
#!/usr/bin/env ruby
# coding: utf-8
class String
def to_dvd
return nil if self.length != 3
(self.split(//).join("・") + "!") * 2
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment