Intro to Fun
Towards Functional Programming with Real Studio
Issue: 10.5 (July/August 2012)
Author: Daniel Gross
Article Description: No description available.
Article Length (in bytes): 21,478
Starting Page Number: 43
RBD Number: 10507
Resource File(s): None
Related Link(s): None
Known Limitations: None
Excerpt of article text...
In recent years, functional programming, a programming paradigm almost as old as programming itself , has seen quite a revival. New multi-paradigm languages, such as Scala  and F# , which offer both object-oriented and functional language facilities, are gaining a large and enthusiastic following amongst Java or .Net programmers. The promise of functional programming is software code that is particularly well suited to run in parallel on multiple CPU cores, and that is often easier to understand, maintain, and change than traditional imperative code written in procedural, or even, object-oriented programming languages.
In this article I focus on the latter traits and make use of a little functional programming library (fun) I implemented to illustrate how functional programming can benefit REALbasic programmers. I first illustrate a typical programming task using standard REALbasic programming techniques. Next I show, in a stepwise manner, how the software code can be rewritten to use a functional programming style. Then I discuss the software engineering advantages, but also possible liabilities, of the functional approach I illustrated. I then conclude the article with a short implementation discussion of the functional library used in the example.
...End of Excerpt. Please purchase the magazine to read the full article.
Article copyrighted by REALbasic Developer magazine. All rights reserved.