The tutorial says that:
One of the biggest problems with declaring variables with the
varkeyword is that you can overwrite variable declarations without an error. In a small application, you might not run into this type of problem, but when your code becomes larger, you might accidentally overwrite a variable that you did not intend to overwrite. Because this behavior does not throw an error, searching and fixing bugs becomes more difficult.
I want to know how this mistake of overwriting declarations with the var keyword a programmer can go into if the application is big (as the tutorial suggests) can lead to unintended results. I want an example on the bugs that can happen in such cases.
Thanks in advance
Challenge: Explore Differences Between the var and let Keywords
Link to the challenge: