© Copyright 2020 Webolution Designs. All Rights Reserved.
Prototypes are a way to make our code more efficient, especially when using constructors. Take the following code for example… Imagine we have one thousand animals. When we use the “new” keyword, the data basically gets copied to the new object. So we would create one thousand grunt functions. Maybe
When writing functions, we might have times when we have argument sent and other times when no arguments are sent to the function. In the cases where no arguments are sent, we might want to have default parameter values. In this case, “Bongo” prints out because we did not send