Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
irb(main):001:0> A = [1,2,3].freeze
=> [1, 2, 3]
irb(main):002:0> A[2] = 5
TypeError: can't modify frozen array
from (irb):2:in `[]='
from (irb):2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.