without multimethod

Methods

without(e:Eachable1, without_elt:Any) Source: stdlib.ngs:1837
Filter out all occurrences of specific value

Parameters

eitems to filter
without_eltThe value to filter out

Returns

Arr

Example

[1,2,3,2].without(2)  # [1,3]
without(e:Eachable2, without_k:Any) Source: stdlib.ngs:2686
Filter out specific key

Parameters

eSource
without_kThe key to filter out

Example

{'a': 1, 'b': 2, 'c': 3}.without('a')  # {'b': 2, 'c': 3}
without(e:Eachable2, without_k:Any, without_v:Any) Source: stdlib.ngs:2696
Filter out specific key-value pair

Parameters

eSource
without_kThe key to filter out
without_vThe value to filter out

Example

{'a': 1, 'b': 2, 'c': 3}.without('a', 1).without('b', 22)  # {'b': 2, 'c': 3}
without(s:Str, r:RegExp) Source: stdlib.ngs:5866
Get string with all occurrences of r removed

Returns

Str

Example

"x10ab20c30y".without(/[0-9]+/)  # "xabcy"
without(ds:ArrLike, without_elt:Any) Source: autoload/DelimStr.ngs:27
Get new DelimStr without the given element

Example

DelimStr("/bin:/usr/bin:/usr/local/bin").without("/usr/bin").Str()  # "/bin:/usr/local/bin"