I'm just starting to research different programming styles (OOP, functional, procedural).
I'm learning JavaScript and starting into underscore.js and came along this small section in the docs.
The docs say that underscore.js can be used in a Object-Oriented or Functional style and that both of these result in the same thing.
_.map([1, 2, 3], function(n){ return n * 2; });
_([1, 2, 3]).map(function(n){ return n * 2; });
I don't understand which one is functional and which one is OOP, and I don't understand why, even after some research into these programming paradigms.