Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
str = 'hello'
puts str.delete 'h' # ello
puts str.delete 'l' # heo
puts str.delete 'f-z' # e ←範囲指定
puts str.delete '^e' # e以外
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment