By now you may have noticed that some of the model methods, such as registerDamage, are prefaced with exports while others, such as eliminateExistingShips, are not. One aspect of good design in complex JavaScript applications is encapsulating the functions that are not designed to be used outside of a certain context. When prefaced with exports, a function can be invoked from a different context, such as from our controller. If it's not designed to be exposed to the rest of the application; in essence, it's a private function. The concept of exporting a variable is similar to the concept of scope in that we're making sure to keep our application clean and expose only the useful bits of the program.
If we take a look at eliminateExistingShips, we can see it's just a helper function used by createRandom to make sure we're not assigning the same ship registry number or name to two different ships. We can see this usage here in createRandom...