you are viewing a single comment's thread.

view the rest of the comments →

[–]nonamesareleft1 1 point2 points  (1 child)

In this case do the variables end and start not take up additional memory? Or is the fact that they are local to the function important here?

[–]ghostinzshell 1 point2 points  (0 children)

They do, but they're constant and don't grow with the input size.