fun filter(predicate: (T) -> Boolean): List<T>
Returns a list containing only elements matching the given predicate.