Guest User

Untitled

a guest
Dec 11th, 2018
81
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.08 KB | None | 0 0
  1. def word_wrap(txt, col = 80)
  2. txt.gsub(/(.{1,#{col + 4}})(\s+|\Z)/, "\\1\n")
  3. end
Add Comment
Please, Sign In to add comment