docs/ARRAY.md in lite-ruby-1.1.8 vs docs/ARRAY.md in lite-ruby-1.1.9
- old
+ new
@@ -233,10 +233,19 @@
```ruby
[:a,:b,:a,:c].indexes(:a) #=> [0, 2]
```
+`match`
+------
+Select a given value from the array.
+
+```ruby
+[1, 2, 3, 4].match(1) #=> 1
+[1, 2, 3, 4].match(9) #=> nil
+```
+
`merge(!)`
------
Concats multiple arrays.
```ruby
@@ -257,10 +266,11 @@
------
Selects given values from the array.
```ruby
[1, 2, 3, 4].only(1, 3) #=> [1, 3]
+[1, 2, 3, 4].only!(8, 9) #=> []
```
`probability`
------
Generates a hash mapping each unique element in the array to the relative frequency, i.e. the probability, of it appearance.
@@ -326,10 +336,10 @@
```ruby
[1, 2, 3, 4, 5].split(3) # => [[1, 2], [4, 5]]
(1..10).to_a.split { |i| i % 3 == 0 } # => [[1, 2], [4, 5], [7, 8], [10]]
```
-`strip(!)`
+`strip(!)` aka `compact_blank(!)`
------
Removes blank elements from an array.
```ruby
['this', '', 'that', nil, false].strip #=> ['this', 'that']