OK… So what does the first line of code do?
You might as well say what the second line of code does - will save me time replying again ;)
You might as well say what the second line of code does - will save me time replying again ;)
So (I guess) both examples set the variable to 1.
That logic of the “break” keyword given a parameter is unusual compared to to other languages.
Maybe it was a bad example to use.