Consider the following functions f and g:
f(){
x = x+1;
x = y*y;
x = x-y;
}
|
g(){
y = y+1;
y = x*x;
y = y-x;
}
|
Suppose we start with initial values of 1 for x and 2 for y and then execute f and g in parallel—that is, at each step we either execute one statement from f or one statement from g. Which of the following is not a possible final state?
- x = 2, y = 2
- x = 5, y = -1
- x = -63, y = 72
- x = 32, y = 5