Example of side effects

This function gets different result every time we call it with parameter 1

    
int externalValue = 1;
int aFunction(int param)
{
    externalValue++;
    return externalValue + param;
}