Skip to content

Instantly share code, notes, and snippets.

@coryschires
Created July 20, 2010 19:00
Show Gist options
  • Select an option

  • Save coryschires/483383 to your computer and use it in GitHub Desktop.

Select an option

Save coryschires/483383 to your computer and use it in GitHub Desktop.
def border(string)
length = (80 - string.length) / 2
border = '+' * length
"#{border} #{string} #{border}"
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment