Advertisement

Pure Functional Programming

  • Thomas Mailund
Chapter

Abstract

A pure function is a function that behaves like a mathematical function: it maps values from one space to another, the same value always maps to the same result, and there is no such thing as a side effect in a mathematical function. The level to which programming languages go to ensure that functions are pure varies, and R does precious little in this regard. Because values are immutable, you have some guarantee about which side effects functions can have, but not much. You can ensure it through careful programming, however.

Keywords

Base Case Binary Search Recursive Function Small Problem Recursive Call 
These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.

Copyright information

© Thomas Mailund 2017

Authors and Affiliations

  • Thomas Mailund
    • 1
  1. 1.Aarhus NDenmark

Personalised recommendations