25.8.20
This website uses cookies to ensure you get the best experience on our website. Learn more

First-class Functions in C++: Defining & Using First-class Functions

Skillsoft issued completion badges are earned based on viewing the percentage required or receiving a passing score when assessment is required. While C++ is considered an object-oriented language, it provides support for functional programming, including support for first-class functions in three manners: function pointers, function objects, and lambdas. In this course, discover the complexity of C-style function pointers by creating them and invoking functions through them. Next, learn about the various features and uses of function pointers and how to accept functions as input arguments and return functions from a higher-order function. Finally, examine function objects (functors) and use them to overload the call operator, instantiate objects, and use the overloaded call operator. Upon completion, you'll be able to list the properties of C++ first-class functions, create function pointers, return functions from a higher-order function, and define and invoke a functor.

Issued on

March 3, 2023

Expires on

Does not expire