DEV Community

Discussion on: [Python] Find the Largest Number From a Array.

Collapse
 
jayjeckel profile image
Jay Jeckel

The passed array doesn't need to be changed and shouldn't be changed by a method that only needs to look at its contents. You've added a side effect to a method that shouldn't have any side effects. Other than a few nitpicks, the article's example of the method is the correct way of doing it.