 made a mistake in a previous video that I should really clarify like if you remember my video on object orientation I discussed the difference between Alan Kay's definition because he was one of the original the proposers of object orientation and the common definition well when I was discussing higher order functions in Ida I only presented the common definition which is to conflate the meaning of a higher order function and a functor as far as the formal correct mathematical definitions go a higher order function is very much not the same thing as a functor a functor does have a higher order function implemented for it a very specific one but they're not the same thing however the common definition is like I said just to treat them as basically synonyms so what I want to show since I already showed what a higher order function is specifically is really what a functor is now I've only implemented this for one of them it was something I wanted to implement anyways because they're remarkably useful you'll hear a lot of functional programmers say map all all create synonyms for these that are called map but I usually go with apply because you're applying the callback to it but apply or map what that does is it takes the the subroutine you pass to it and calls that on every single element of the object I'm using object in the general sense here data type it calls it on every single value within that data type so in the case of array it iterates over the array taking each value calls the the callback on it and then returns a new in this case an array with the result there's obviously a very useful thing to have defined because you're talking about the entire looping being done for you just the minor convenience you know you can get away without it but it is definitely a convenient thing to have the presence of this is specifically what makes the array a functor any array that would not have this defined any list or heap or anything that does not have this map or apply function defined for it is not a functor so in this case while array is the functor apply or map is a higher-order function that's the difference