Found table http://phrogz.net/programmingruby/language.html#table_18.4 but unable to find description for |=
|=
How the |= assignment operator works?
When working with arrays |= is useful for uniquely appending to an array.
>> x = [1,2,3] >> y = [3,4,5] >> x |= y >> x => [1, 2, 3, 4, 5]
1.4m articles
1.4m replys
5 comments
57.0k users