This is one of the alternative ways that I could wrap myself around this. Let be f(ref i)a function that takes in I by reference and increases its value by 1. So,f(ref i) = i + 1
Now that we have f(ref i), the above code can be written as
int i = 10
while( (f(ref i) -1) <=10 )
{
f(ref i);
}
I would replace with f(ref i)equivalent values I will return it and get an answer like
while(11 - 1 <= 10) {12}
while (13 -1 <= 10) -> break;
so i = 13.
source
share