Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Referential transparency

Name: Anonymous 2009-07-28 15:02

A function is RT <=> it can be substituted by its value in any place of the code, right? So what's the difference between a function being referentially transparent and not having side effects? Can I get an example of a function that is one but isn't the other one?

Name: Anonymous 2009-07-28 16:35

time() has a side effect if you consider I/O to always be a side effect.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List