@tuxOr
There is nothing to do with the signature of a function.
A function is pure if and only if
So in your example, assuming process(var1, var2) will make some side effect somewhere else in the program, it is not a pure function.
process(var1, var2)
However, if process do not make any changes, then it will still be a pure function.
process
I think I understood now, thank you!
Are you sure you want to hide this comment? It will become hidden in your post, but will still be visible via the comment's permalink.
Hide child comments as well
Confirm
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
@tuxOr
There is nothing to do with the signature of a function.
A function is pure if and only if
So in your example, assuming
process(var1, var2)
will make some side effect somewhere else in the program, it is not a pure function.However, if
process
do not make any changes, then it will still be a pure function.I think I understood now, thank you!