Hands On: Higher Order Functions
In this exercise we are going to get some hands on practice using higher order functions. We are going to have a form simulating a ticket booking UI. The user can enter the number of tickets to book and submit the form to book the tickets. Problem Statement There are three pieces of code that we will deal with in this exercise: * A Form object that accepts the number of tickets to book from the user * A book_tickets function that simulates a call to the backend with the number of tickets t
Understanding function composition
The foundation of programming is to take smaller abstractions and make bigger abstractions out of it. In the previous articles in this series, we learned about using functions to create abstractions. Now let us look at how to join them up together using functional composition.