You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

19 lines
663 B

  1. \emph{Referential transparency}, as in:
  2. \slidep
  3. \begin{itemizep}
  4. \item everything (variables, data structures...) is \emph{immutable}
  5. \item expressions never have side-effects (remember: mathematical functions)
  6. \item same input $\mapsto$ same output... \emph{always}!
  7. \item replace a function with it's (return) value? Yes. What happens in C or java if you do that? Remember \cppinline{void pop();}?
  8. \end{itemizep}
  9. \slidep
  10. \vspace{\baselineskip}
  11. possible benefits?
  12. \begin{itemizep}
  13. \item parallelism
  14. \item equational reasoning and refactoring
  15. \item less bugs!
  16. \end{itemizep}
  17. \slidep
  18. \vspace{\baselineskip}
  19. Question: call-by-value? call-by-reference? call-by-need?