A component should only do one thing, if it gets bigger it shoulld broken down into smaller subcomponents.
To build a static version of an application basically means to build a version that takes the data model and renders a UI but has no interactivity. In a static version it is important to use props and not state. This is helpful to flush out all the components and see how the application will be laid out and function without user interaction that may create problems.
props?
If the answer is yes to these, they are probably not state.
Identify every component that renders something based on that state.
Find a common owner component (a single component above all the components that need the state in the hierarchy).
Either the common owner or another component higher up in the hierarchy should own the state.
If you can’t find a component where it makes sense to own the state, create a new component solely for holding the state and add it somewhere in the hierarchy above the common owner component.
https://reactjs.org/docs/thinking-in-react.html
Functions that operate on other functions, either by taking them as arguments or by returning them, are called higher-order functions. https://eloquentjavascript.net/05_higher_order.html#h_xxCc98lOBK
Line two is an arrow function within the greaterThan function, it returns the value ‘m’ when it is greater than ‘n.’
Both map and reduce can be included within another function in order to manipulate an array.