Logo

Programming-Idioms

History of Idiom 247 > diff from v2 to v3

Edit summary for version 3 by programming-idioms.org:
+Related URL Idiom #57: Filter list

Version 2

2020-12-09, 11:53:41

Version 3

2020-12-09, 11:55:07

Idiom #247 Filter list in-place

Remove all the items from list x that don't satisfy the predicate p, without allocating a new list.

For languages that don't have mutable lists, refer to idiom #57 instead.

Idiom #247 Filter list in-place

Remove all the items from list x that don't satisfy the predicate p, without allocating a new list.

For languages that don't have mutable lists, refer to idiom #57 instead.

Variables
x,p
Extra Keywords
keep conserve preserve mutable
Extra Keywords
keep conserve preserve mutable