And mathematically speaking, a function never has side effects -- it only takes values for arguments and returns values in response. Any side effects, including changing the value of the arguments, violates referential transparency.
So why should a function that returns a random number, or that returns the current time, require an input argument? It seems to me that it makes perfect sense for such functions to not take any arguments and return a value.
So why should a function that returns a random number, or that returns the current time, require an input argument? It seems to me that it makes perfect sense for such functions to not take any arguments and return a value.