Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.


  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint

16.6. What You've Learned

In this chapter, we discussed functional programming. Along the way, you learned the following:

  • Programs written in the functional style always give the same result when they are given the same values in their arguments.

  • Functional programs do not contain side effects. Their whole purpose in life is to just calculate a value to return.

  • Programs that are not functional usually read like a cookbook, with statements like, “First do this, and then do that.” This style of programming is called imperative programming.

  • A good strategy for writing Lisp programs is to break them into a clean, functional part and a dirty, imperative part.

  • Functional programs can be written quickly, are more compact, and tend to have fewer bugs, particularly in the hands of an experienced functional programmer.


  

You are currently reading a PREVIEW of this book.

                                                                                        

Get instant access to over
$1 million worth of books and videos.

  

Start a Free Trial