What does it mean that functions are first class objects

Hello everyone,

what does it mean that functions are first-class objects in javascript?
What’re the other classes and why are they different?


Hello @giuliovallata.

I means that functions can work and do mostly everything that other objects, like strings, can do. They can be stored to variables, etc. This provides a good summary of first class objects.

Classes are just types of data-basically. You should get a better introduction into classes in some of the later lessons, I think. Other classes include strings, ints, floats, arrays, etc.
I hope this helps!


Thank you @codeneutrino. Your answer it’s pretty helpful to me.