What are Func, Action, and Predicate delegates? When do you use them?
Ask by ICSM Computer
Updated 22 Jun 2025
What are
Func<>,Action<>, andPredicate<>delegates? When do you use them?These are built-in generic delegates:
Func<T, TResult>: Takes parameters, returns a value.Action<T>: Takes parameters, returns void.Predicate<T>: Takes one input, returnsbool.Use them with LINQ, events, callbacks, or to make APIs more flexible.