SE450: Function Objects: Strategy [45/47] |
We know how to do part of an algorithm, but not all.
Example: filter values in a list based on a predicate.
Example: sort values in a list based on a comparison operator.
Example: apply a function to every value in a list, creating a new list.
Let's look at a non-software example: file:links-main
java.util.Arrays#sort(T[],%20java.util.Comparator)
java.util.Collections#sort(java.util.List,%20java.util.Comparator)
java.util.Comparator