Many operations change the state of the program through assignment, casting, etc. Do branch operations ( conditional statements ) change the state of the program? Or do they simply translate, depending on certain conditions, into one of the parts of the general state?
As I understand it, the state of the program is the entire set of calculated and / or used values, potentially volatile and / or constant at the moment of the running program. I could be wrong, of course.
I can't imagine the state of a program without a pointer to the currently executing command …
Therefore, I believe that any branching operation changes the state of the program. However, like any operation in general – because the state of the program at the very beginning of execution and at its very end is unlikely to be called identical by anyone, right? 🙂